Need to store date(in string ) into MS Access (in Date fromat)
-
Hi, I need to store a Date, which is in String format, into MS Access Table where the C# is used as front end... Can anybody provide me the Sample code for the same Date string is in "dd/mm/yyyy" format... Thanks in Advance
Use
DateTime.TryParse
on your string to convert it into a date and time, then store it in your database in UTC format.Deja View - the feeling that you've seen this post before.
-
Hi, I need to store a Date, which is in String format, into MS Access Table where the C# is used as front end... Can anybody provide me the Sample code for the same Date string is in "dd/mm/yyyy" format... Thanks in Advance
Don't forget that when storing a date string in Access it needs to be prefixed and suffixed with "#".
Just because we can; does not mean we should.