TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Ari
NA
8
51.1k
C# DateTimePicker problem
Dec 1 2011 10:13 PM
Hey, I'm trying to use some basic input validation for two dateTimePicker controls in an application I'm building.
I'm trying to set it so that the issueDatePicker's value or date & time must be smaller (less than) that of the dueDatePicker's value or date & time.
I'm using this code which seems correct but just isn't working..
if (issueDatePicker.Value >= dueDatePicker.Value)
{
MessageBox.Show("The due date must be greater than the issue date", "Input Error");
}
else
{
issueDate = issueDatePicker.Value;
dueDate = dueDatePicker.Value;
dateCorrect = true;
}
The above code is within a button click event.
Any help is appreciated.
Reply
Answers (
2
)
Updation of exe on netwrok PC
Access form from another class in c#