| | |
Validating DateTimePicker
Please support our C++ advertiser: Intel Parallel Studio Home
![]() |
Im not sure if Im doing it right but... I have changed the datetimepicker to ValueChanged so now I dont have compare option to compare the datetimepicker with Now().CurrentDate()
PLease let me know if u have an idea
PLease let me know if u have an idea
Some people get so rich they lose all respect for humanity. That's how rich I want to be.
I have a datetime picker, then I have ValueChanged event handler for it and a code that goes like this
but now its trhowing exception that said date is not valid I cant even open my form
DateTime date = DateTime::Parse(dtpDate->Text); System::DateTime::Compare(date, System::DateTime::Today.Now);
but now its trhowing exception that said date is not valid I cant even open my form
Some people get so rich they lose all respect for humanity. That's how rich I want to be.
•
•
Join Date: Oct 2008
Posts: 25
Reputation:
Solved Threads: 0
what is tis line suposed to asign to varible date ?
why do you try to compere it in this way ?
try instad
in onchange event
C++ Syntax (Toggle Plain Text)
DateTime date = DateTime::Parse(dtpDate->Text);
why do you try to compere it in this way ?
try instad
C++ Syntax (Toggle Plain Text)
if (Now().CurrentDate()<DateTimePicker1->Date) { //your code }
![]() |
Other Threads in the C++ Forum
- Previous Thread: Soap and problem with timeout
- Next Thread: Urgent Request on Printing
| Thread Tools | Search this Thread |
api application array arrays beginner binary bitmap c++ c/c++ calculator char class classes code coding compile compiler console conversion convert count data database delete desktop developer directshow dll dynamic email encryption error file forms fstream function functions game generator getline google graph homeworkhelper iamthwee ifstream input int integer java lib linkedlist linker linux loop looping loops map math matrix memory multiple newbie news node number numbertoword output parameter pointer problem program programming project proxy python random read recursion recursive return sorting string strings struct template templates test text tree unix url vector video visualstudio win32 windows winsock word wordfrequency wxwidgets





