|
The wxAutomationObject class represents an OLE automation object containing a single data member, an IDispatch pointer. It contains a number of functions that make it easy to perform automation operations and set and get properties. The class makes heavy use of the wxVariant class and is only available under Windows. The usage of these classes is quite close to OLE automation usage in Visual Basic. The API is high-level, and the application can specify multiple properties in a single string. The following example gets the current Excel instance, and if it exists, makes the active cell bold: wxAutomationObject excelObject; if (excelObject.GetInstance("Excel.Application")) excelObject.PutProperty("ActiveCell.Font.Bold", true); |
|