TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
puskar maji
NA
20
0
dropdown
Feb 2 2009 1:25 AM
SqlDataAdapter da1 = new SqlDataAdapter("select * from menu_cat where res_id=" + Context.Request.QueryString["id"], con);
da1.Fill(ds1, "menu_cat");
cat_dd.DataSource = ds1;
cat_dd.DataTextField = "cat_name";
cat_dd.DataValueField = "cat_id";
cat_dd.DataBind();
now i want to know if above sql does not fetch any record then i want to populate cat_dd dropdown box as "select" value only. but bellow code does not working.
if (cat_dd.Selectedvalue == null)
{
// cat_dd.DataTextField = "Select....";
}
Reply
Answers (
2
)
File Saving Problem
Conversion of a Tab Delimited (.txt) file to Comma Delimited (.txt) file