Some times it happens we cannot fix the payload element for generating the filename and hence forth variable substitution does not work. We have Michal pointing out to get the same filename from sender file adapter and update the file name using the Dynamic Configuration class during the mapping. But what if I have Idoc as sender adapter? Do I need to do it in custom module? This was the issue raised by Bikram Paul in the forum that has triggered me to share this with everyone as it is useful to all.
Many forum posts deal with accessing the system parameters in mapping which can be easily achieved.If we can understand the system classes then we can implement it in UDF.
System classes are documented athttp://help.sap.com/javadocs/pi/SP3/xpi/com/sap/aii/mapping/api/package-summary.html%3E%20System%20Classes%20for%20accessing%20system%20parameters%20in%20the%20mapping%20runtime%3C/a%3E%3C/body%3E%3C/html%3E
with sample examples also.
You observe that we use get method incase of accessing sender information and the put method for setting receiver adapter specific information. The thorough reading of the system classes avoids you raising a forum thread and waiting for a response.