How To Use the New AutoVerbMenu Property of OLE Controls

Last reviewed: January 10, 1997
Article ID: Q156241
The information in this article applies to:
  • Microsoft Visual FoxPro for Windows, version 5.0

SUMMARY

The OLE Container Control and OLE Bound Control have a new property called AutoVerbMenu, which allows you to specify whether a pop-up menu appears when the user right-clicks an OLE object in a running form.

MORE INFORMATION

The list of items on the pop-up menu are the verbs supplied by the server. They are the same ones you see when Object is clicked on the Edit menu.

Steps to Demonstrate

  1. Create a new form.

  2. Add an OLE Container Control to the form.

  3. Select Microsoft Excel Worksheet in the Insert Object dialog box.

  4. Enter some data and deactivate the Excel object.

  5. With the Excel object selected, click Worksheet Object on the Edit menu. The Edit and Open menu options appear.

  6. Set the AutoVerbMenu and Enabled properties for the object to .T. - True.

  7. Run the form and right-click the worksheet.

The same items (Edit, Open) that are available on the Edit menu are available to the user of your form when they right-click the worksheet object.

REFERENCES

Visual FoxPro Help, version 5.0; search one: AutoVerbMenu topic. (A right- click on this property in the Property window does not bring up this Help topic.)


KBCategory: kbinterop kb3rdparty kbhowto
KBSubcategory: FxinteropOle
Additional reference words: 5.00 kbdsd VFoxWin



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.

Last reviewed: January 10, 1997
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.