Email Attachment’s filename

Home Page Forums BizTalk 2004 – BizTalk 2010 Email Attachment’s filename Email Attachment’s filename

#13520

Merry,

The FILE.ReceivedFileName property will return the complete path of the received file.

To extract just the filename you will need code like this:

[code:1:7cf09cb70c]OriginalPath = ReceivedMessageType(FILE.ReceivedFileName);
OriginalFN = OriginalPath.Substring(OriginalPath.LastIndexOf(’\\\\’) + 1);
SMTPUtils.Part.SetFileName(MSGtoSend.Attachment,OriginalFN); [/code:1:7cf09cb70c]

You do not need a custom pipeline component. The FILE.ReceivedFileName property is set by the File Adapter.