i have a problem on ms access 2016 (on the recent versions it's worked fine). the problem is that by my country the Date format is dd/mm/yy but for sql queries on access i has to change the date format to mm/dd/yyyy. if not i don't get the right results.
so i have this function that change the date to a string that is mm/dd/yyyy and on every sql string on vba that is using a date field i use this module like this:
"select * FROM InvoiceT WHERE InvoiceDate>=#" & fixdate(me.invoiceDate) & "#"
this is the module
Public Function FixDates(d As Date) As String
FixDates = month(d) & "/" & DAY(d) & "/" & year(d)
Until now was a successful solution, but for some reason now when i write this code;
that the result has to be on mm/dd/yy format 10/01/2015 but the result is 12/30/1899