Search code examples
biztalkflat-filebiztalk2006r2biztalk-orchestrationsbiztalk-pipelines

BizTalk ExecuteReceivePipeline can't accept XmdlDocument parameter


I'm trying to call a receive pipeline from the orchestration in order to catch any type of flatfile_to_xml error.

After searching for tutorials, the process seemed quite easy. Added the libraries, created my inputMsg of type xmlDocument to inglobe any non-Xml payload (in my case the content of my file.txt) and created an atomic scope containing an expression for:

  Microsoft.XLANGs.Pipeline.XLANGPipelineManager
     .ExecuteReceivePipeline(typeof(namespace.pipelineName), msgIN);

Too bad I get that ExecuteReceivePipeline can't accept a XmlDocument while it accepts only a Microsoft.XLANGs.BaseType.XLANGMessage).

Cannot connvert from 'System.Xml.XmlDocument' to 'Microsoft.XLANGs.BaseTypes.XLANGMEssage'

Why this, and how can I achieve what I'm trying to achieve?


Solution

  • Ok, now it's working and i'm not sure why. At first the msgIN of type XmlDocument wasn't accepted as a valid parameter. I then created a msgType of type XmlDocument, and assigned it as the type of the message, so that calling:

    ExecuteReceivePipeline(typeof(namespace.pipelineName), msgIN)
    

    would be valid. after many rebuild and deploy i switched back to msgIn as XmlDocument... and it worked as intended...

    I don't get it, but it's not the first time that a rebuild or a close-and-reopen of VS solved my preblems. Thanks for those who found the time to answer!