XL97: Macro Error Accessing OLEObject on WorksheetLast reviewed: March 13, 1998Article ID: Q159858 |
The information in this article applies to:
SYMPTOMSYou may receive the following error when you run a Visual Basic for Applications macro that accesses an OLEObject on a worksheet:
Run-time error '1004': Unable to get the OLEObjects property of the Worksheet class CAUSETo access an OLE object on a worksheet using the OLEObjects method, you must specify the drawing object name for the object. The drawing object name is the name that appears in the Name box when the worksheet object is selected. You may receive the error described if you do not use the "drawing object name" with the OLEObjects method.
RESOLUTIONMicrosoft provides examples of Visual Basic for Applications procedures for illustration only, without warranty either expressed or implied, including, but not limited to the implied warranties of merchantability and/or fitness for a particular purpose. The Visual Basic procedures in this article are provided 'as is' and Microsoft does not guarantee that they can be used in all situations. While Microsoft support engineers can help explain the functionality of a particular macro, they will not modify these examples to provide added functionality, nor will they help you construct macros to meet your specific needs. If you have limited programming experience, you may want to consult one of the Microsoft Solution Providers. Solution Providers offer a wide range of fee-based services, including creating custom macros. For more information about Microsoft Solution Providers, call Microsoft Customer Information Service at (800) 426-9400. If you change the Name property for an OLE object on your worksheet, you should also change the drawing object name so that the names are the same. The following steps illustrate how this problem may occur and how you can correct it.
STATUSMicrosoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.
MORE INFORMATIONThe Name box is the box at the left end of the formula bar that identifies the selected cell, chart item or drawing object. To display the Name box, click Options on the Tools menu, click the View tab, select Formula Bar and click OK.
|
Additional query words: XL97 8.00 checkbox command button text box
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |