Results 1 to 4 of 4
  1. #1
    5 Star Lounger
    Join Date
    Mar 2001
    Location
    New York, NY
    Posts
    860
    Thanks
    0
    Thanked 10 Times in 9 Posts
    I have a Word 2007 VBA project where I reference MS Windows Common Controls (mscomct2.ocx) so I can use the Datepicker. This has worked well for me. I took it to the office, and tested and modified the template on a PC there. I experienced no problem. Now when I open the template on my own PC, I get an error saying that an "object is not installed on this machine."

    I have the ocs file stored in c:\windwos\SysWOW64.

    Can anyone suggest why I don't have trouble going from home to office, but office to home creates a problem?

    Thanks,
    Richard Barrett

  2. #2
    Platinum Lounger
    Join Date
    Dec 2009
    Location
    Earth
    Posts
    3,619
    Thanks
    7
    Thanked 231 Times in 219 Posts
    I'm guessing here, but I would suspect you have other controls loaded at the office that are not loaded at home. I had a spreadsheet for showing loaded controls here somewhere.

    Aha! Attached the file.
    You need to enable macros, then run Grab_References.

    cheers, Paul
    Attached Files Attached Files

  3. #3
    5 Star Lounger
    Join Date
    Mar 2001
    Location
    New York, NY
    Posts
    860
    Thanks
    0
    Thanked 10 Times in 9 Posts
    The "missing" control is the datepicker. When I open the VBA project, a message displays for each occurrence of that control in the user forms. But I can go to those forms and drag the datepicker from the toolbox.

    I created this template on the home PC, so I know all of the controls in use are installed. If I had had this problem at the office, I would have been less surprised; possibly the ocx was missing there. But I had no problem running and modifying the code, so it would appear that the common control ocx was loaded there.

    I'm wondering if the office had a later version of the control; it was backward compatible when I went TO the office, but not when I came FROM the office.

  4. #4
    Super Moderator
    Join Date
    Jan 2001
    Location
    Melbourne, Victoria, Australia
    Posts
    3,515
    Thanks
    3
    Thanked 143 Times in 136 Posts
    I think this is a backwards/forwards version issue. In my experience, if I attach a control to the oldest available version and then open the template which has a newer version of the same control then it happily upgrades. BUT, when I attach a newer control then it doesn't automatically attach the older version of the control.

    I think this is forwards compatible but not backwards compatible.
    Andrew Lockton, Chrysalis Design, Melbourne Australia

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •