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
NETFAN
NA
13
0
Select item on GridView
May 11 2005 4:27 AM
Hi, I have the following problem. I have a Calendar on a page with a dateselect method and a Gridview with a Select item enabled, no datasource connected. The Grid is filled via a dataset .... On dateselect -> fills the GridView When I run it, it says it cant do a Databind. And its probably because I enabled AutoGenerateSelectButton. I need because I need to be able to select an item from the gridview. Anyone? protected void Calender_Schedule_SelectionChanged(object sender, EventArgs e) { int day, month, year; string sql; day = Calender_Schedule.SelectedDate.Day; month = Calender_Schedule.SelectedDate.Month; year = Calender_Schedule.SelectedDate.Year; sql = "select * from schedule where Scheduleday='" + day.ToString() + "' and Schedulemonth='" + month.ToString() + "' and Scheduleyear='" + year.ToString() + "'"; SqlDataAdapter Ad = new SqlDataAdapter(sql, Conn); DataSet ds = new DataSet(); Ad.Fill(ds, "Schedule"); GridView_Schedule.DataSource = ds; GridView_Schedule.DataBind(); }
Hope this code helps you Thx Kind regards NETFAN
Reply
Answers (
1
)
help on implement a "next" feature when displaying database values
I try to update GridView but get error