## INF: Right-Clicking OLE Object Invokes Object Frame Properties

Article ID: Q114681
Creation Date: 10-MAY-1994
Revision Date: 05-FEB-1996

The information in this article applies to:

- Microsoft Access Developer's Toolkit version 2.0

SUMMARY

Moderate: Requires basic macro, coding, and interoperability skills.

To view the property sheet for an object in a form or report in Design view in Microsoft Access, using the right mouse button (right-click), you can click with the mouse pointer in the object, and then click Properties. However, when you do this with an OLE object, such as the Calendar control, instead of invoking a list of properties for the Calendar control, you invoke a list of properties for the object frame.

This is correct behavior because, to Microsoft Access, the control is an object frame only. Essentially, the object frame is a place holder in the form for the OLE control. The OLE control connected to the object frame has its own properties, events, and methods that are separate and distinct from those of the object frame.

To see the properties, events, and methods for the OLE object, right-click the OLE object, and then click the name of the OLE object.

NOTE: In Microsoft Access for Windows 95 version 7.0, the properties for the OLE Object are listed under the Other tab on the property sheet. Also, clicking the Build button for the Custom property will show the object's properties in a dialog box format.

MORE INFORMATION

The following example uses the Calendar control included with the Microsoft Access Developer's Toolkit version 2.0 to demonstrate the differences between object frame properties and OLE object properties:

1. Start Microsoft Access and open any database.
2. Create a new form not based on any table or query, and then add an unbound object frame control to the form.
3. In the Insert Object dialog box, click the Insert Control option button.
4. In the Control Type box, select Calendar Control, and then click OK.
5. If the property sheet is not already open, open it by clicking the Properties button on the toolbar. Note the "Object Frame: Embedded0" title for the property sheet. The property sheet contains the properties for the object frame itself, not for the Calendar control contained in the object frame.
6. Right-click the Calendar control.
7. Click the Calendar Control Object, and then click Properties. Note that a dialog box showing the Calendar control properties is displayed.

REFERENCES

For more information about embedded OLE objects, search for "unbound object frame," and then "Embedding an OLE Object in an Unbound Object Frame" using the Microsoft Access Help menu.

> THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

©1997 Microsoft Corporation. All rights reserved. Legal Notices.
Additional reference words: 2.00 adt
KBCategory: kbole
KBSubcategory: IntpOle