Date Formats

Hey everyone, I have to date formats one is yyyy/month/ day and the other is Month/Day/Year

date.Parse(row(emdDateIndex).ToString).CompareTo(date.Parse(row(dueDateIndex).ToString)) < 0

Error I get is “If: String was not recognized as a valid DateTime” above is the code I have now

1 Like

HI Buddy,
@seanp92

Its resolved buddy, here is your xaml for this

timedae.xaml (7.2 KB)

The reason is whenever you try to convert a string to datetime format, kindly change it in the same format like if you have string in 2019/02/26, change it to yyyy/MM/dd, not like we need like MM/dd/yyyy. It should match between the string and the dateformat and there are two options to do that one is parse and parseexact. To better know about this kindly refer to this link

Hope this would help you,if so buddy kindly close this thread with comment marked as solution that could help others looking for ideas under you topic
Cheers…

1 Like

Is that working buddy…

If so close this topic by marking the comment as solution that could help others.
@seanp92
Cheers

1 Like