cancel
Showing results for 
Search instead for 
Did you mean: 

about the script and define keyword....

Former Member
0 Kudos

DEFINE &FIELD_VALUE& = 'X'

IF &FIELD_VALUE& NE INITIAL_VALUE

IF &RPBEN_DB-ERNOC& EQ 'X'

EMPLOYEE &RPBEN_DB-ERCST()& &RPBEN_DB-CURRE()&

ELSE

EMPLOYER CREDIT &RPBEN_DB-ERCST(8)& &RPBEN_DB-CURRE(*)&

ENDIF

IF &RPBEN_DB-MODEL& NE &SPACE(4)&

&RPBEN_DB-TXT_MODEL&

ENDIF

ENDIF

In this what is the use of define keyword and if condition...... where exactly we need to use this define keyword...... and if condition........

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

DEFINE Value assignment to text symbols

DEFINE: Value assignment to text symbols

Text symbols receive their value through an explicit assignment. This assignment can be made interactively in the editor via the menu options Include Symbols Text. This lists all the text symbols of a text module, as well as those of the allocated layout set.

The contents defined in this way are lost if the transaction is exited. To continue printing the text module, you would have to enter the symbol values again.The DEFINE command allows you to anchor this value assignment firmly in the text, to also have it available when you next call up the text. Furthermore, you can allocate another value to a text symbol in

the course of the text.


Syntax:
/: DEFINE &symbolname& = ‘value’

Example:
/: DEFINE &re& = ‘Your correspondence of 3/17/94’
Example:
/: DEFINE &symbol1& = ‘xxxxxxx’
/: DEFINE &symbol2& = ‘yyy&symbol1&’
/: DEFINE &symbol1& = ‘zzzzzzz’
Result: &symbol2& yyyzzzzzzz 

The assigned value may have a maximum of 60 characters. It can also contain further symbols. When a symbol is defined using the control command DEFINE, symbols which occur in the value are not immediately replaced by their value. They are only replaced when the target symbol is output. If the operator := is used in the DEFINE statement, all symbols which occur in the value which is to be assigned are immediately replaced by their current values. The resulting character string is only then assigned to the target symbol when all occurring symbols have been replaced. The length of the value is limited to 80 characters. The target symbol must be a text symbol, as at present.


Syntax:
/: DEFINE &symbolname& := ‘value’