Академический Документы
Профессиональный Документы
Культура Документы
STATUS ICON
Status icon is used in screens to indicate visually about the status of the
program.Before the status icon can be used ,it should be placed on the
screen,it is a type of screen element.
To use the status icon we have to write some abap code and also to
change icons whenever required in the program. First step is to create
a variable of type ICONS-TEXT.
Here name can be anything like ICON_RED_LIGHT,ICON_GREEN_LIGHT etc. Infact any icon
can be shown that exists but we should adhere to SAP
recommended style guidelines
CONTEXT MENU
Context menu can be used in relation with the various screen elements
like I/O fields, subscreen,group box,table control but not with push buttons,radio,check buttons.
It can be used to show related options when the user right clicks on the screen elements. It is a
type of status. SAP automatically creates a default context menu for dialog statuses consisting of
all the function codes available.
We can create a context menu statically using the menu painter(SE41)
or dynamically by using the methods of the global class CL_CTMENU.
All context menus are objects of this global class.
There are number of methods which can be used to create and modify context menu
dynamically . These are:
LOAD_GUI_STATUS
This method is used to load a static context menu already defined using
menu painter.The exporting parameters are PROGRAM ,STATUS and MENU. Where MENU
indicates the menu to which the context menu will be attached .
ADD_FUNCTION
This method adds a function code to the menu ,The exporting parameters are FCODE and
TEXT. These are used to specify the function code and the corresponding text in the men.
ADD_MENU
This method adds a context menu to another one.
ADD_SEPARATOR
This method adds a separator line.
ADD_SUBMENU
This method adds a menu to another one as a sub menu the exporting parameters are MENU
and the TEXT that will be displayed.
HIDE_FUNCTIONS
SHOW_FUNCTIONS
DISABLE_FUNCTIONS
ENABLE_FUNCTIONS
These functions are used to modify the context menu by hiding,enabling etc them.
SET_DEFAULT_FUNCTION
This method will mark a particular menu item as the default one ,the corresponding function
code is passed as an exporting parameter.
The context menu should be linked to the screen element in the screen painte(SE51) by
specifying an ID which is known as CONTEXT in the context menu field.
We can specify the same context for different screen elements or different context for different
elements.
For each context specified in the screen painter a special call back
subroutine is used in the abap program. the syntax of this special routine
is:
The ABAP program should check for the OK_CODE field to find out whichmenu item was
selected by the user. Selecting a function code will trigger a PAI while right clicking will not
trigger the PAI.
SCREEN KEYWORDS
Screen language is used to create Screen Flow Logic, It is similar to ABAP but with limited
functionality .Only certain keywords can be used
and these are:
PROCESS
MODULE
FIELD
ON
LOOP
ENDLOOP
CHAIN
ENDCHAIN
CALL
SCREEN EVENTS
Screen Flow Logic serves as the cotainer for screen processing blocks.There are four events
processing block supported out of which
FIRST two are automatically inserted when we create a new screen. The 4 events are: