Add a date to a Userform

O

ordnance1

I am using Office 2010 in advance of roll-out in our organization. I have
been testing some of our VBA enabled templates for compatibility and have
run into a problem. Specifically a lose of the Calendar control. Since we
have a number of Userforms that use the calendar control, I need to come up
with some sort of replacement. Any suggestions? I thought there was a date
picker control, but I can not find it (I have installed the complete Office
2010 Professional Plus)
 
J

joel

The calendar control uses the library

c:\program Files\Microsoft Office\Office13\MSAL.OCX


Usually the 1st time you use a control like the Calendar control on a
PC you need to right click the userfrom Toolbox and select "additional
controls". Then choose Calendar control by clicking the X and pressing
ok. the control will then be added to the toolbox. Then you can add
the control to a userform from the toolbox. When you do this in the VBA
menu tools - References and library is automatically added as a
rerference.


Sometimes after an update to a PC the reference doesn't get updated to
point to the newer version of office. Then you have to browse for the
library by going to the VBA menu Tools - References - Browse, select the
calendar control, and look for the location of the MSAL.OCX. Usually I
will go to a Window browser and try to locate the file by doing a search
in the Program Files folder before I add the refence to the VBA menu to
make sure the file exists.

There are ways of automatically adding the reference to workbook using
a macro but I would have to do a little research to find the macro. I
also believe this can be done in a window script.
 
P

p45cal

Can't speak for 2010 but in 2007 it's
In the Controls Toolbox, right-click in some empty space and choos
*Additional Controls…*, in the ensuing list it is called:
MICROSOFT DATE AND TIME PICKER CONTROL 6.0 (SP4)


I am using Office 2010 in advance of roll-out in our organization.
have
 
O

ordnance1

Thanks

I have done what you suggested (had run regsvr32 in both the
Windows\system32 and the windows\syswow64 folders. I was able to select
mscal.ocx (tools, reference, browse) and the checl Calendar Control 11, but
when I select additional tools Calendar Control still is not listed. BTW
this is Office 14 (2010).
 
O

ordnance1

I may have solved my problem. Having followed all advice offered I got
mscal.ocx registered but it seems it will only work on the 32 bit version of
office 2010 (I am testing both versions for compatibility). If anyone has a
solution to get it to work in Office 2010 (64 bit) I would love to hear
about it. IT department is insistent they want to run the 64 bit version
since they migrated to Win7 64 bit.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top