Biztalk multipart message with null member

431 views Asked by At

I created one POP3 receive location which sends the email to one orchestration. The message I use for this is a multipart message, one part is for the Attachment and the second part is for the body. When I send an email with attachment everything goes fine. But when I send an email without attachment, even before I process the message, I get an exception:

Exception thrown from: segment 3, progress 3
Inner exception: The XLANG/s message has no part at index '1'.  The total number of parts found in the message is '1'. If you expect a multipart message, check that the pipeline supports multipart messages such as MIME.

the message in the suspended message, contains of course one part (only the body) as there is no attachment.

Is there any way to handle it or filter the receive component in the orchestration?

1

There are 1 answers

1
felixmondelo On

Which is the configuration of your Receive Location? Seems that you have setted the Body Part Index property to 1 and according to the documentation:

Otherwise if the Body Part Index is set to a value greater than 0 and the Body Part Content Type is blank, then the body part with the specified index is selected as the BizTalk message body part. If the specified index is greater than the number of body parts then the message is suspended.

Read this document Processing Multi Part Messages with the POP3 Adapter, this can help you.