how can i validate that the date and time in the following string is in the right format i.e year, month, day and then the time(4 digits, 2 digits, 2 digits and then the time)
"Event (No 3) 0007141706 at 2010/04/27 11:48 ( Pacific )"
thanks
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
This will check if your string contains a date and time in the specified format.
It does however only check the amount of digits, so a string containing
2010/13/99 93:71would be equally valid. Which it is not.