InsertClass
PowerScript function
Description
Inserts a new object of the specified OLE class in an OLE
control.
Syntax
|
1 |
ole2control.InsertClass ( classname ) |
|
Argument |
Description |
|---|---|
|
ole2control |
The name of the OLE control in which you want to create a |
|
classname |
A string whose value is the name of the class of the |
Return value
Integer. Returns 0 if it succeeds and one of the following negative
values if an error occurs:
-1 — Invalid class name
-9 — Other error
If any argument’s value is null, InsertClass returns null.
Usage
Classnames are stored in the Registration database. Examples of
classnames include:
Excel.Sheet
Excel.Chart
Word.Document
Examples
This example inserts an empty Excel spreadsheet into the OLE
control, ole_1:
|
1 2 |
integer result result = ole_1.InsertClass("excel.sheet") |
See also
Document get from Powerbuilder help
Thank you for watching.
Subscribe
Login
0 Comments
Oldest