Setting From Email Address in Email Report Server/400 based on RPTUSER Setting in User Defined Data
From Support
Have a need to set the from email address for a mailed report based on the original AS/400 report user ID, so that if messages are replied to or emails bounce back, they will end up in the appropriate mailbox.
Needs to set a from email address based on the original user id for a report that has gone through the report splitter, the following methods have been enabled to handle this:
Contents |
Step 1
Download and install AS/400 Report Splitter version 4.17 or above.
Step 2
Download and install Email Report Server/400 version 1.83 or above.
Step 3
In the AS/400 Report Splitter "Edit Report Distribution Settings", specify the following values for new user defined data to place the original report user ID into the User Defined Data field when the report gets split:
RPTUSER: @USERID
This will place the original report user ID along with the special keyword: RPTUSER: in the user defined data. The Email Report Server/400 will use this setting to look up the from address from the Email Report Server/400 address book when the report gets mailed.
Step 4
Create an address book entry in the Email Report Server/400 for the desired from address and assign the System i user based on the original report user ID from the previous step. This address book entry will be used to set the from email address when *USERDEF is specified for the from email address on the MAILSPLF or ERSMON commands.
Note: If an address book entry is not found for the original report user ID or the RPTUSER: key is not found in the user defined data field for the report, the system default setting for from email address will be used automatically when mailing the report.
