Find more freelance jobs
|
58
.... /: DEFINE &mysymbol& = `abc' * &mysymbol& .... Print program: .... Data: mysymbol(5) value `xyz'. .... In this example, in the form/text instead of &mysymbol& the value of the text symbol defined with DEFINE is printed: abc Form/text: .... * &mysymbol& /: DEFINE &mysymbol& = `abc' .... Print program: .... Data: mysymbol(5) value `xyz'. .... In this example, in the form/text instead of &mysymbol& the value of the program symbol defined in the print program is printed: xyz Usually, SAPscript looks for the table work areas and the global variables in the main part of the ABAP program that was started. For example, if you call function modules that you want to use the table work areas, enter the name of the corresponding program in the field TDPROGRAM of the structure you can enter in the OPTIONS parameter at OPEN_FORM. This definition is then valid for all program symbols up to the next CLOSE_FORM. However, you can also specify the name of the program in the PROGRAM parameter of the START_FORM function module. If you do this, it will be valid up to the next END_FORM. If this parameter is not set in START_FORM, then the setting in OPEN_FORM applies. For formatting a program symbol, SAPscript uses the specifications found in the Dictionary (output length, formatting routine, and so on). Certain data types require additional information out of other fields to format a value. For example, the contents of a currency field can be formatted correctly only when the information from the currency field key is also available. SAPscript itself is responsible for obtaining the necessary information from the Dictionary. For printing the program symbols, SAPscript uses the WRITE statement of the ABAP programming language. The effect of this statement is controlled externally via parameters (such as specifications in the user master record, table T005X), depending on the data type. If a program symbol is not printed in the way you expected it, first check whether the control parameters stated above are set correctly. To fields of the table work areas shown below, you can refer in all SAPscript text modules: 7.3.1 SYST: System Fields in the ABAP Programming Environment You can refer to all the fields in this table. You should, however, note that some of the fields are specific to a certain environment. They contain values that do not come from your application but have been set by the SAPscript programming environment (for example, SYST-REPID). 7.3.2 USR03: User Address Data This structure contains information from the user master record for a given user: · Business address · Telecommunication (telephone, telefax) · Other data such as user language, department, cost center. You can maintain the contents of these fields in the `Address' section of the user maintenance. If this table exists in the calling program, then SAPscript copies the data from the work area of this program. Otherwise, SAPscript uses the values for the currently active user. |