Reputation: 1129
I would like to update a control (in date format) to the current date and ensure that it's format is solid (e.g. not containing hours and seconds). In this example, i am trying to update the control 'AsOfDateL1'. The error message I am getting is Runtime error '6' Overflow
AsOfDateL1 = CDate(Format((Now()), yyyy / mm / dd))
Upvotes: 0
Views: 3726
Reputation: 6075
You have to wrap the date format with double quotes if you plan to use Format
like that.
AsOfDateL1 = CDate(Format((Now()), "yyyy/mm/dd"))
Upvotes: 1