Welcome Guest Search | Active Topics | Sign In | Register

Clear Datepicker to null value Options
89geronimo
Posted: Saturday, January 7, 2012 5:23:41 AM
Rank: Newbie
Groups: Member

Joined: 1/7/2012
Posts: 4
Hi sir,

I have more than 10 datepicker on a webform, after the user have selected the date, I need to clear it to "" or null.

How can I do on javascript and in codebehind (vb)

Thank you
89geronimo
Posted: Saturday, January 7, 2012 6:01:24 AM
Rank: Newbie
Groups: Member

Joined: 1/7/2012
Posts: 4
For Codebehind :

Dim dt As Date = Nothing
DatePicker1.VisibleDate = dt
DatePicker1.SelectedDate = dt (this clear the datepicker)
eo_support
Posted: Saturday, January 7, 2012 9:03:18 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

Set SelectedDate to DateTime.MinValue.

Thanks


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.