Educational Materials like Computer, engineering, software and Property , Entertainment: Validation for future date in c sharp dot net lanugage
Custom Search

Subscribe Now: Feed Icon

January 6, 2012

Validation for future date in c sharp dot net lanugage

Axapta Code solutions   Education and Entertainments  Earn Money its Real  Experience of knowledge  Imortant Weblink collections   Fun and Entertainment   God thoughts   Get Ways to Invest your money   Products overview and details

Validation for future date in c sharp dot net lanugage

you can write this code in validation class which you may have in common class file.

public static bool IsNotFuturedt(DateTimePicker datpic)
       {
           if (datpic.Value.Date > DateTime.Now.Date)
           {
               MessageBox.Show("Please enter date less than today ");
               datpic.Value = DateTime.Now;
               datpic.Focus();
               return false;
           }
           else
           {
               return true;
           }
       }

0 comments:

Post a Comment

Follow by Email

Video Bar

Loading...

Followers

Educational Materials like Computer, engineering, software and Property , Entertainment

Recent Visitors

Active Search Results
Wink Bingo | Slots Tips | Football manager 2010 | blackjack free | Poker Stars
Submitdomainname.com