问题
I created a simple interface that send an email. I have set the filename by
msg_out_renamed(MIME.FileName) = FileName;
This works fine in my outlook 2013, it shows as "client_inv_20160909090658.csv"
.
But the receipient who uses Outlook 2016 has it show up as "body.csv". When he decides to save the attachment the filename in the save as dialog is "client_inv_20160909090658.csv"
.
Why does this happen and is there a way i can prevent this from happening?
回答1:
Change the context property MIME.FileName for the part of your attachment as well.
In an orchestration: (note the ".part" code)
Message.part(MIME.FileName) = "NewFileName.txt";
In a pipeline component: (note the ".BodyPart" code)
pInMsg.BodyPart.PartProperties.Write("FileName", "http://schemas.microsoft.com/BizTalk/2003/mime-properties", "NewFileName.txt");
Unfortunately we cannot see these context properties via the Message details screen in the BizTalk console. Attach a debugger to inspect these values.
来源:https://stackoverflow.com/questions/39407158/why-is-the-email-atachment-i-sent-by-biztalk-body-csv-in-outlook-2016