BizTalk SMTP Adapter

I have created an orchestration in BizTalk that looks at a folder and based on the file name sends the file to a different location.  I used the the decide shape and created several diffent send ports (File) which specify different folder locations.  On the Else decision I want to move the file into an Unknown folder and send an email to the admin.  I am able to move the file without issues...  I then created a send port group and created another send port (SMTP) to email the admin.  However the email port is not working, the SMTP adapter is configure with a working server and the Pipeline on the port is set to PassThruTransmit.
Who is Participating?
snidenikConnect With a Mentor Commented:
I am not sure why you have created multople IF condition for Filename...this task can be done using one Dynamic Send port , File.ReceivedFileNameProperty and %SourceFileName% property at the send ports.

you can also sned the email using dynamic send port using following code will work...please make sure you SMTP server name property of SMTP adapter is configured at Platform-> Hosts
I have created a video for sending email using SMTP adapter can found the same at
it has everything you needed
Dept808Author Commented:
Do you think you could elaborate more on how to use the dynamic port to route a flat file to different directories based on filename?
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.