Hi
I have created One Application in C#.Net (Windows Appplication) and i have take two calendar drop down
1st is Start Date and 2nd is End Date While searching between start Date and End Date if user can enter the less date in end Date Box than Start Date So it should show the validation..
how it is possible please help me ..
Thanks and Regards
Kamlesh Nikam
Loading
Suthish NairPosted Feb 4, 2011, 2:16 PM
So other members can easily find the answers.
Madhu KPosted Feb 2, 2011, 2:31 AM
My mistake missed it.
Suthish NairPosted Feb 2, 2011, 2:28 AM
Its a windows application.
Madhu KPosted Feb 2, 2011, 1:14 AM
ControlToValidate="TextBox2"
OnServerValidate="CustomValidator1_ServerValidate">
protected void CustomValidator1_ServerValidate(object source, ServerValidateEventArgs args)
{
DateTime dt = Convert.ToDateTime("10/13/2010");
if (DateTime.Compare(Convert.ToDateTime(TextBox2.Text), dt) >= 0)
{
args.IsValid = true;
}
else
{
args.IsValid = false;
}
}
Suthish NairPosted Feb 1, 2011, 6:26 AM