Hi,
I have a combobox named[listDateSelect] which allows users to filter records from my PrepareQuery table/query. The field[listDateSelect] has:
What I need is to format the [PrepareDate] with YYYY-MM
I have tried a number of times in applying the 'Format' function. Though the commands were not prompting any errors, still I cannot get the results I wanted (usually blank or zero records were displayed).
Thanks team,
Josh
I have a combobox named[listDateSelect] which allows users to filter records from my PrepareQuery table/query. The field[listDateSelect] has:
Code:
recordsource = "SELECT DISTINCT Format ([PrepareDate],"yyyy-mm") AS [YYYY-MM] FROM PrepareQuery ORDER BY Format([PrepareDate],"yyyy-mm") DESC"
Code:
Me.Filter = "Format([PrepareDate],"yyyy-mm") = " & Me.listDateSelect Me.FilterOn = True Me.Requery Me.Refresh
Thanks team,
Josh
Comment