Click here to Skip to main content
15,907,874 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
XML
DateTime date = dtpDate.Value;

           if ((date.CompareTo(Convert.ToDateTime("01/04/2012")) >= 0) && (date.CompareTo(Convert.ToDateTime("31/03/2013")) <= 1))
           {
               //return value
               return true;

           }

here between two dates is compare but i want 01/04/2012 and 31/03/2013 also comapre...
Posted
Updated 22-Oct-13 2:33am
v4

1 solution

See this: DateTime.Compare Method [msdn] [^]

Regards..
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900