Link Server
Use
You define it with reference to the interface i_oi_link_server.
The link server manages the objects of the SAP system (internal tables, fields, documents, graphics,...) that are integrated in the office application when the program is executed. The link server also provides methods for managing and creating links to the office application.
The instance contains the SAP system objects that users can incorporate in the office documents. You also save a list of permitted objects on the link server.
Prerequisites
Before proceeding, you must create a central instance of type i_oi_container_control for Managing Desktop Office Integration.
Process
-
Initialization
Declare an instance with reference to interface i_oi_link_server:
data: link_server type ref to i_oi_link_server.
-
Use the method get_link_server on the central object for Desktop Office Integration control to create an instance for the link server.
-
Start the link server with method start_link_server.
-
Document Design Phase
Use methods add_string_item, add_table_item and add_binary_item to add items to the link server. Use method remove_link_item to delete items from the link server.
-
The data in the link server is placed on the clipboard of the desktop application using the copy_link_item_to_clipboard method.
-
Document Runtime
If you have changed the data in your application program, and need to update it in the desktop application, use methods add_string_item, add_table_item and add_binary_item to update them.
-
Before you leave your program, use method stop_link_server to switch off the link server and release the memory area.