Datagrid

J

john pryor

I have a calendar control in the edit field of a template column of a
datagrid control and I don't know how to capture the events generated when a
user changes dates. Once the calendar control is on the template it doesn't
expose any events for me to capture, how can I fix this?
 
W

Weston Weems

You can bind events in OnItemCreated, etc...

But it really depends on what youre trying to do. I
suspect your not needed an event to be fired but rather
consume the selected date for re-inserting back into the
db.

If thats the case, you should be able to get a reference
to the datarow and the control itself by doing this...

DataRowView drv = (DataRowView)e.DataItem;
and
Control
((Calendar)e.FindControl("Calendar1")).SelectedDate

though again I dont know the ultimate effect you are
shooting for.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,065
Latest member
OrderGreenAcreCBD

Latest Threads

Top