Entering content frameSyntax documentation init_control Locate the document in its SAP Library structure

You use this method to create the object that manages the link to the OLE interface.

CALL METHOD control->init_control
   EXPORTING parent                   = parent
             r3_application_name      = r3_application_name
             inplace_enabled          = inplace_enabled
             inplace_show_toolbars    = inplace_show_toolbar
             inplace_scroll_documents = inplace_scroll_documents
             inplace_resize_documents = inplace_resize_documents
             shell_style              = shell_style
             autoalign                = autoalign
             no_flush                 = no_flush
             register_on_close_event  = register_on_close_event
             register_on_custom_event = register_on_custom_event
             rep_id                   = rep_id
             dynpro_nr                = dynpro_nr
             gui_container            = gui_container
             inplace_mode             = inplace_mode
             parent_id                = parent_id
   IMPORTING retcode                  = retcode
             error                    = error.

Description of parameters

Parameter

Optional

Description

parent

 

Name of the container in which you want to start the desktop office application.

r3_application_name

 

Heading

inplace_enabled

X

'X': Allows a document to be opened in-place.

' ': No documents may be opened in-place.

inplace_show_toolbar

X

Show the toolbar of the desktop application (when inplace_enabled = ‘X’)

inplace_scroll_documents

X

Show the scrollbars of the desktop application (when inplace_enabled = ‘X’)

inplace_resize_documents

X

Resize the document display when the R/3 window is resized (when inplace_enabled = ‘X’)

autoalign

 

'X': Fill the entire control container with the office application.

shell_style

X

The display format of the container control in the R/3 screen Possible values are contained in the include <SAPOLECONTAINERCONTROL>. You do not normally have to change the default value of the parameter.

register_on_close_event

X

Registers the event triggered when the office application user closes the document. If you want to react to this event in your ABAP program, register with "X".

register_on_custom_event

X

Registers additional events in the office application (for example, macro calls) Pass the value "X" to react to this event in your ABAP program.

rep_id

X

Obsolete. Previous use:

Names the program or the module pool of the screen in which the office application will be displayed. (If you have not specified a container but want to process the events from the desktop application).

dynpro_nr

X

Obsolete. Previous use:

Number of the screen on which you want to create the SAP Document Container Control. (If you have not specified a container but want to process the events from the desktop application).

gui_container

X

Obsolete. Previous use:

Name of the container defined in the Screen Painter for which the SAP Document Container Control should be created.

parent_id

X

Obsolete. Previous use:

Dialog box level at which the control appears:

dynpro_0 to dynpro_9: The control is displayed at dialog box level 0 (on the R/3 screen) to level 9 (ninth-level dialog box).

dynpro_default : Determines automatically the active level at the point where the method is called. This is the level that is then used. This only works if the call occurs in the PBO event.

inplace_mode

X

This parameter is obsolete. Do not use it in new programs.

Note

For further information about event handling, refer to Processing Office Application Events.

 

Leaving content frame