Hi all,
I have a quick (hopefully easy) problem for you today. I have an options screen for a report in my current Access project that asks the user for a starting date and a duration. My starting date field is to be inputted as "mm/yy" (ex. 11/12) for ease of use.
When reading this as a date, however, I found it was transferring the data in "mm/dd" format, not "mm/yy". To work around this, I was formatting the string to retrieve the month ("mm") and year ("dd") and "adding" a day value of "/01/" to it.
ex: newDate = Format(oldDate, "mm") & "/01/" & Format(oldDate, "dd")
Though this was an extremely clunky solution, all was well until I tried to run a report for previous years. "11/00 (November 2000)" reads as "11/01" in my current scheme, because "00" is obviously an invalid day.
Long story short, I need to know if there is a way of reading an input of "mm/yy" AS "mm/yy" instead of "mm/dd".
Thanks in advance.
I have a quick (hopefully easy) problem for you today. I have an options screen for a report in my current Access project that asks the user for a starting date and a duration. My starting date field is to be inputted as "mm/yy" (ex. 11/12) for ease of use.
When reading this as a date, however, I found it was transferring the data in "mm/dd" format, not "mm/yy". To work around this, I was formatting the string to retrieve the month ("mm") and year ("dd") and "adding" a day value of "/01/" to it.
ex: newDate = Format(oldDate, "mm") & "/01/" & Format(oldDate, "dd")
Though this was an extremely clunky solution, all was well until I tried to run a report for previous years. "11/00 (November 2000)" reads as "11/01" in my current scheme, because "00" is obviously an invalid day.
Long story short, I need to know if there is a way of reading an input of "mm/yy" AS "mm/yy" instead of "mm/dd".
Thanks in advance.