Welcome Guest Search | Active Topics | Sign In | Register

Enable DatePicker client side with VBScript Options
Ron Rushing
Posted: Monday, November 24, 2008 2:18:40 PM
Rank: Member
Groups: Member

Joined: 10/28/2008
Posts: 23
How can I enable the datapicker control with Client Side VBScript. When the form initially loads it will be enabled = False.

I tried Form1.Datapicker1.disabled = False but this throws an error.
eo_support
Posted: Monday, November 24, 2008 4:31:54 PM
Rank: Administration
Groups: Administration

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

I do not think you can do that at client side. I believe you can set the controls Enabled to false on the server side and then use a CallbackPanel/UpdatePanel to AJAX update it if necessary.

Thanks!
Ron Rushing
Posted: Monday, November 24, 2008 7:24:32 PM
Rank: Member
Groups: Member

Joined: 10/28/2008
Posts: 23
How can I clear the datapicker selecteddate value server side via vb.net. How can I determine if the selecteddate has a value via server side via vb.net?
eo_support
Posted: Tuesday, November 25, 2008 6:00:31 AM
Rank: Administration
Groups: Administration

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

You would do it by setting the DatePicker's SelectedValue to DateTime.MinValue. DatePicker regards DateTime.MinValue as blank. Likewise, you determine if it has a value by comparing SelectedValue with DateTime.MinValue.

Thanks!
Ron Rushing
Posted: Tuesday, November 25, 2008 1:42:15 PM
Rank: Member
Groups: Member

Joined: 10/28/2008
Posts: 23
I don't follow ... by DateTime.MinValue are you referring to SelectedDate.Date.MinValue?
eo_support
Posted: Tuesday, November 25, 2008 6:31:47 PM
Rank: Administration
Groups: Administration

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

It's System.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.