Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved


Chapter 3 Tools : MESSAGE

MESSAGE
Returns a customized message by taking a root message in the MESSAGES table and inserting customizing tokens. (F)
Invocation
m = MESSAGE (utility, msg_num, tokenlist)
 
Usage Notes
Message text is contained in the MESSAGES table, which is parameterized by utility. You can use this table to contain the messages for your applications. The utility parameter value cannot start with an at sign (@).
MESSAGE customizes the message by replacing each percent sign (%) in the root message with the next token in the list of tokens. If no such message exists in the MESSAGES table, MESSAGE returns a message indicating this.
Separate multiple tokens in tokenlist with spaces.
Example
The example rule is used by a function key. SCREENMSG uses MESSAGE to return a value and MESSAGE modifies the root message for the EMPLOYEE utility:

 
RULE EDITOR ===> SCROLL: P
DEL_EMP_2;
_
_ ---------------------------------------------------------------------------
_ ------------------------------------------------------------+--------------
_ GET EMPLOYEE_INFO('DELETE_EMPLOYEE'); | 1
_ GET EMPLOYEES(EMPLOYEE_INFO.REGION) WHERE EMPNO = | 2
_ EMPLOYEE_INFO.EMPNO; |
_ CALL CONFIRMACTION('DELETE_EMPLOYEE', | 3
_ 'ABOUT TO DELETE EMPLOYEE ' || EMPLOYEE_INFO.EMPNO, |
_ 'PF22', '', '', ''); |
_ DELETE EMPLOYEES(EMPLOYEE_INFO.REGION); | 4
_ CALL SCREENMSG('DELETE_EMPLOYEE', MESSAGE('EMPLOYEE', 2, | 5
_ EMPLOYEE_INFO.EMPNO)); |
_ --------------------------------------------------------------------------

 
In this example, the root message in the MESSAGES(EMPLOYEE) table is:
Deleted employee with no.: %
After deleting the employee, the following screen message appears:
Deleted employee with no.: 99999

Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved