The information in this article applies to:
IMPORTANT: This article contains information about editing the registry. Before you edit the registry, make sure you understand how to restore it if a problem occurs. For information about how to do this, view the "Restoring the Registry" Help topic in Regedit.exe or the "Restoring a Registry Key" Help topic in Regedt32.exe. WARNING: Using Registry Editor incorrectly can cause serious problems that may require you to reinstall your operating system. Microsoft cannot guarantee that problems resulting from the incorrect use of Registry Editor can be solved. Use Registry Editor at your own risk. For information about how to edit the registry, view the "Changing Keys and Values" Help topic in Registry Editor (Regedit.exe) or the "Add and Delete Information in the Registry" and "Edit Registry Data" Help topics in Regedt32.exe. Note that you should back up the registry before you edit it. If you are running Windows NT, you should also update your Emergency Repair Disk (ERD). SYMPTOMSYou receive the following error when attempting to automate either a Microsoft Office application or an ActiveX server created with Visual Basic: This problem only occurs on computers running Microsoft Windows NT 4.0. CAUSEThis problem can occur if the ActiveX server is installed to a long folder path that may conflict with a similar path on the computer. Usually, the problem occurs when the path of the ActiveX server contains spaces and another path on the computer is the same, up to a space. For example, suppose you have this problem when you try to automate a Microsoft Office application. If you installed Microsoft Office to the default path: C:\Program Files\Microsoft Officeand you also have a folder named C:\Program or C:\Program Files\Microsoft, you might experience this problem. A conflicting folder can also appear on a different drive. RESOLUTIONHere are three resolutions:
To locate the LocalServer32 key for your ActiveX server, choose Find from the Edit menu and specify the file name of your ActiveX server (or search on the ProgID). For example, to find the LocalServer32 key for Microsoft Excel, search for "Excel.exe." You might need to press the F3 key to Find Next until you see the LocalServer32 key. For the case of Microsoft Excel, the LocalServer32 value might be: C:\Program Files\Microsoft Office\Office\excel.exe /automationAssuming that the short path is C:\Progra~1\Micros~1\Office, you can change the LocalServer32 value to: C:\Progra~1\Micros~1\Office\excel.exe /automationYou should only have to change one LocalServer32 key for your ActiveX server. To determine exactly what to specify for the short path, check the properties of the ActiveX server file in the Windows Explorer. See the MS- DOS name setting in the Properties window. Also check the properties of the folder in which the ActiveX server resides so that you can determine the complete short path of your ActiveX server. Another way to determine the short path is to use the GetShortPathName API function. For more information about using the GetShortPathName API function, see the following article in the Microsoft Knowledge Base: Q175512 HOWTO: Get a Short Filename from a Long Filename STATUSMicrosoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article. MORE INFORMATIONSteps to Reproduce Behavior
Result: MsgBox displays "Microsoft Excel."
REFERENCESFor additional information, please click the article numbers below to view the articles in the Microsoft Knowledge Base: Q173430 Off97: Error Inserting an Office Object Under Windows NT 4.0 Q244264 INFO: Error 429 When Automating Office Applications Q167591 ACC97: "Microsoft Access Can't Find the Wizard" Error Message Q189366 ACC97: Run-Time Error 429 Message Using Run-Time Application Additional query words: GetObject instantiate COM CoCreateInstance
Keywords : kbActiveX kbOLEApp kbVBp500 kbGrpDSO kbOffice2000 kbVBA500 |
Last Reviewed: January 13, 2000 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |