How to Read OLE Type Library Information in Visual FoxPro (139389)



The information in this article applies to:

  • Microsoft Visual FoxPro for Windows 3.0

This article was previously published under Q139389

SUMMARY

Visual FoxPro allows the use of OLE controls in your applications. These controls are available from a variety of sources. Often, it is necessary to determine the names of the properties, methods, and events available in an OLE control.

MORE INFORMATION

This information is available through the OLE control's type library, which was created by the .ocx developer. Visual FoxPro allows you to read this information programmatically by using the AMEMBERS() function.

Steps to Determine Events, Methods, and Properties Exposed in an .Ocx File

  1. Create a new form.
  2. Add an OLE Container control to the form.
  3. On the Insert menu, click Control, and select the desired control.
  4. Save and run the form. Minimize the form.
  5. In the Command window, type:
       =AMEMBERS(aType, formname.olecontrol1,1)
       _SCREEN.SHOW
       DISPLAY MEMORY LIKE aType
    						
The array containing the exposed properties and methods of the .ocx should be displayed.

Modification Type:MajorLast Reviewed:2/10/2000
Keywords:KB139389