Click here to Skip to main content
15,896,502 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
how do we give the option for selecting date 3times greater than current month.
Posted
Updated 28-Feb-12 23:01pm
v3
Comments
Sergey Alexandrovich Kryukov 29-Feb-12 2:40am    
Please, follow a good friendly advice: 1) no shouting (ALL CAPS is considered shouting on the Web, pretty rude); 2) correct spelling and punctuation (at least). Otherwise many will be very irritated. "Improve question" is above.

Add "Ajax" to the tags. You are interested to bring your question to attention of right experts (sorry, in this case this is not me).
--SA
OriginalGriff 29-Feb-12 4:51am    
DON'T SHOUT. Using all capitals is considered shouting on the internet, and rude (using all lower case is considered childish). Use proper capitalisation if you want to be taken seriously.

1 solution

Try:
C#
DateTime selectedDate = new DateTime(2012, 5, 17);
if (selectedDate > DateTime.Now.AddMonths(3))
    {
    ...
    }
 
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