tags:

views:

24

answers:

1

Hi,

The only way I could find is to write a custom .NET assembly to perform the task. Is there a way to do it within expression in orchestration? I have an input message that has parts and I'd like to copy those to the destination (mapped) message. Thank you.

A: 

It basically depends what those parts are, but assuming we're talking about parts that aren't explicitly presented in a multi-part message type, and/or you don't want to use a map for each one, then yeah, the only way is through a helper component.

tomasr
Thank you Tomas,I googled and figured that that would be the only way. Too bad. That means that every time my multipart untyped message goes through dynamic transformation, I have to remember to copy the attachments with an external .NET helper class. I wish there would be something build in in Orchestration syntax to copy parts... also, weird thing I encountered, is that body part Name was "part" and not "Body". Really strange.
Sean
There's really nothing strange about the latter; the name of the body part is meaningless really, the important part is that it has been marked as the body part when it was added to the message :)
tomasr
My understanding from the read was that the body part has to be named as "body". As well as it's not enough to mark it IsBody=true, it also has to be added as the first part in the sequence of part (multi-part message case). That's why I was surprised to see that body part message got a different name.
Sean
Sean: I've never personally run into a case where that's required at all, though I can certainly imagine some components or bugs creeping up that might expect that. Still, it's not generally an issue.
tomasr