If you've attended one of our Excel VBA training courses you might remember using the Date and Time Picker control when building a user form.
- One of our clients has several VBA macros in excel 2013 with the date picker control in VBA. All are working fine in 2008R2. He copied the same VBA and tried in 2012R2 /excel 2013. Date picker control was not available. I did some research and learned that Microsoft packed the control as.ocx which we need to download/copy and register it.
- If you are running 32-bit version of Excel, generally we could take the steps you have mentioned in your thread to register the calendar control in your system. I tested in my current Excel 2013 (32-bit) and Windows 10 (64-bit) by following the detailed instructions in the article below and the control can be registered properly.
- For 32 bit Office, Microsoft Date and Time Picker will be available as part of the installation. If missing, let me know For 64 bit Office, you will need to resort to third party controls.
An exciting shot of the Date and Time Picker in action. As its name suggests, it allows a user to pick a date and time value rather than having to type it in.
The Date and Time Picker is immensely useful when designing VBA user forms but, sadly, it isn't included with every version of Windows. I discovered this recently when moving to a new machine with a 64bit edition of Windows 7 installed. Fortunately, it is relatively simple to install the Date and Time Picker, as long as you don't mind getting your hands dirty with a couple of simple command line instructions.
Downloading the Files You'll Need
The Date and Time Picker is part of a library of tools with the catchy title of MSCOMCT2.OCX. To start with, you'll need to download this file from the Microsoft support site.
Date Picker for Excel inserts a pop-up calendar into Microsoft Excel. It works like a drop-down calendar, offering a handy date selector. As long as the date picker app is running, it activates the pop-up calendar in all the Excel files you open. It does not require you to insert an additional control into any particular Excel. Find out step by step instructions on how to fix Monthview Control Missing In Office 2016. Get 24x7 Support for Microsoft related products.
Click this link on the page to start downloading the file.
UPDATE: Sadly, Microsoft have since removed this file from their site. You can still download it from a variety of third-party sites which you can find with a brief bit of Googling.
When you've clicked the link to start downloading the file, choose to save it somewhere on your computer.
Click the Save as option so that you can choose where to save the file.
On the next dialog box choose a location on your computer and then click Save to download the file.
Extracting the Downloaded File
Once it's finished downloading you'll need to extract the file. Start by double-clicking on the file that you've downloaded.
Double-click the .cab file to see what it contains.
Once inside the .cab file you can choose to extract the .ocx file by right-clicking on it and choosing Extract...
Right-click the file called mscomct2.ocx and choose to extract it.
Choose which folder you want to extract the file to and click Extract.
Select an existing folder, or create a new one, and then click Extract.
Copying the File to the Correct Folder
In order to make use of the file you've downloaded you'll need to place it in the correct folder for the edition of Windows that you're using. Start by opening a Windows Explorer window and browsing to the Windows installation folder. On my machine this is C:Windows.
The next folder you need to browse to depends on which edition of Windows you're using. If you're using a 32bit edition you'll need the System32 folder. If you're using a 64bit edition, like I am, you'll need SysWOW64.
Once you've navigated to the correct folder, simply move or copy the MSCOMCT2.OCX file into it.
The file now sits in the correct folder.
Registering the File
Before you can make use of the file you'll need to register it. You can do this using the command line tool in Windows. Go to the Start menu and in the search box type cmd.
Type cmd into the search box at the bottom of the Start menu.
Still in the Start menu, right-click on the cmd.exe item which appears and choose to run it as an adminstrator.
Right-click on the icon and choose Run as administrator.
At the command prompt make sure that the directory shown is the same as the one you copied the file into earlier.
If I was running a 32bit edition of Windows 7 this would be pointing to the correct folder.
If you need to change the directory you can do so using a command similar to the one shown below. Of course, you'll need to use the directory relevant to your own Windows installation.
Press Enter at the end of the line to change the directory.
Once you've changed the directory you can write one final command to register the file on your machine.
For reference, the command is regsvr32 mscomct2.ocx
Microsoft Monthview Control 6 0 Excel 2013 Missing Persons
If everything works normally you should see a message similar to the one shown below:
Using the Date and Time Picker
You should now find that you can use the Date and Time Picker control in your VBA forms.
Microsoft Monthview Control 6 0 Excel 2013 Missing Word
In the design view of a VBA form, right-click on the Toolbox and choose Additional Controls...
Microsoft Monthview Control 6 0 Excel 2013 Missing Numbers
On the dialog box which appears, check the box next to the entry for the Microsoft Date and Time Picker Control 6.0.
Microsoft Monthview Control 6.0 Excel 2013 Missing
You'll find that you have access to several other controls from the mscomct2.ocx library as well.