ABAP Keyword Documentation → ABAP - Reference → Data Interfaces and Communication Interfaces → ABAP and OLE
SET PROPERTY - OLE
Other versions: 7.31 | 7.40 | 7.54
Syntax
SET PROPERTY OF ole attr = dobj [NO FLUSH]
[EXPORTING p1 = f1 p2 = f2 ...].
Extras
2. ... EXPORTING p1 = f1 p2 = f2 ...
Effect
The attribute attr
of an automation object ole
is set in accordance with the content of the data object dobj
. The automation
object must have been created using the special statement CREATE OBJECT
for automation objects. For the
typing of ole
,
the description of the statement CREATE OBJECT
applies. The typing of the
data object dobj
depends on the properties of the automation attribute attr
.
System Fields
sy-subrc | Meaning |
---|---|
0 | Object attributes passed successfully. |
1 | Error in communication with SAP GUI. |
2 | Error in function call in SAP GUI. |
3 | Error when setting an attribute. |
4 | Error when reading an attribute. |
Addition 1
... NO FLUSH
Effect
The meaning of the addition NO FLUSH
is included in the description of the statement CREATE OBJECT
.
Addition 2
... EXPORTING p1 = f1 p2 = f2 ...
Effect
The addition EXPORTING
can be assigned to the parameters p1
p2 ... of the attribute's actual parameters f1 f2 ...
, where the data type of the data objects f1 f2 ...
depends on the requirements of the attribute.
Example
Calls the Office application Excel and displays an empty Excel table by assigning the value 1 to the attribute "Visible".
DATA app TYPE ole2_object.
CREATE OBJECT app 'Excel.Application'.
SET PROPERTY OF app 'Visible' = 1.