I have a "date heavy" application, but want to provide the calendar function to allow the user to look for a date - say for example the last friday in a month etc.
So, I have one form called DataEntry which contains the date fields that need to be entered. Next to each field there is a button.
Taking one button. The on-click event opens a form which contains the calendar active x control.
The vba for the button looks like.... docmd.openform "calendarpopup",,,,,,,,"forms!dataentry!date1"
"forms!dataentry!date1" is a variable, accessible in the calendarpopup form by openargs.
My question is.... how can I set fieldname (passed via openargs) to the returned value of the activex control. If I was hard coding it, I would say forms!dataentry!date1 = me!activectl0
Many thanks in advance...