Kourier Integrator Online Help
SUBROUTINE KMK.FMTMAIL (F.DICT, ID, REC, PARMS, WIDTH, ETID, MESSAGE, ERROR_FLAG, ERROR_MESSAGE)
This subroutine formats an email message.
F.DICT |
File pointer to where dictionaries reside. |
ID |
Item-id of current data record (needed for substitutions). |
REC |
The current data record (needed for substitutions). |
PARMS |
Dynamic substitution parameters value-mark delimited. |
WIDTH |
Width of the output. |
ETID |
Item-id of KT_EMAIL_TEMPLATE item or null. |
MESSAGE |
Undefined if ETID is non-null otherwise contains the contents of the message in standard DW substitution format. |
ERROR_FLAG |
Undefined. |
ERROR_MESSAGE |
Undefined. |
F.DICT |
Unchanged. |
ID |
Unchanged. |
REC |
Unchanged. |
PARMS |
Unchanged. |
WIDTH |
Unchanged. |
ETID |
Unchanged. |
MESSAGE |
Contains the email message with substitutions performed. |
ERROR_FLAG |
If non-null, displays the message number to issue. |
ERROR_MESSAGE |
Parameters required by the message. |
CALL HW.OPEN('DICT CUSTOMER',FD.CUST,OFLAG,1) CALL HW.OPEN('CUSTOMER',F.CUST,OFLAG,1) ID = '1000' READ CUST FROM F.CUST, ID ELSE STOP PARMS = '' ;* No Program Values WIDTH = '' ;* Use Default Width ETID = 'MSO-001' ;* Email Template ID CALL KMK.FMTMAIL(FD.CUST,ID,CUST,PARMS,WIDTH,ETID,MSG,ERRNO,ERRMSG) IF ERRNO THEN PRINT ERRMSG