I am currently trying to convert some vb into c# and in the vb code I have the following line:
If DateTime.TryParse(txtExpirationDate.Text, Nothing) = False Then
_isValid = False
Which, with my extremely limited knowledge of vb, I think should read in c# as:
if (DateTime.TryParse(txtExpirationDate.Text, null) == false)
_isValid = false;
However visual studio is telling me that I have invalid arguments:
The best overloaded method match for 'System.DateTime.TryParse(string, out System.DateTime)' has some invalid arguments
I was wondering if anyone would be willing to help me out. What am I doing wrong? Is this even possible in c# and if so how would I do it?