private bool ValidDateCheck(){
bool _isValid = true;
try{
DateTime.Parse("07/&*/2009");
DateTime d = Convert.ToDateTime("07/&*/2009");
}
catch{
_isValid = false;
}
return _isValid;
}
How does the above code not throw an exception?
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 is from the .NET 1.1 documentation:
I am unable to test this as the earliest version I can build with in VS2008 is 2.0.