Default value for Calendar

  • Thread starter Thread starter Leszek
  • Start date Start date
L

Leszek

Hello,

I would like to set the current date as a default value for my Calendar
control.
How to accomplish this?

Thanks,
Leszek Taratuta
 
There is a Today Method for the Calendar Control.

Me.MyCalendarControl.Today

Check Access VB Help on the Today Method of the Calendar Control.
 
It works fine for me in A2K and AXP!

Assuming that you use the Calendar Control that comes with Access, describe
how you use the Calendar Control and which Event you use to run the Today
Method.
 
I don't think the AXControl is instantiated yet in the Form_Open Event.
In my code, I use the Load Event.

I checked one of my databases using Calendar 9.0 in A2K and the Today Method
works fine with the Form_Load Event.
 
The Access VB Help has little information about this method:

"You can use the Today method to set the value of the Calendar control to
today's date: controlname.Today
The Today method has the following argument: controlname - The name of the
Calendar control object."

I am a little bit confused about this description. Anyway when I have tried
to use the Today method it does not work properly: Me.MyCalendar.Today

The calendar control is set by default on a day when I created the control
on a form (it's wierd, isn't it?) and any method cannot change it!

Any other suggestions?
Leszek Taratuta
 
Back
Top