Dynamically Configuring pipeline components

Posted: January 19, 2009  |  Categories: BizTalk Uncategorized

How do you dynamically configure pipeline component properties in a BizTalk Orchestration with out a send port configured to use the  pipeline?

I am doing a lot of work with un=typed documents at the moment and have to call pipelines within the orchestrations to do the work. I do not want to hard code the properties of the pipeline component property. I tried the following code in an assign shape but it does not work;

xDocCopy = xDoc;
xDocCopy(BTS.SendPipelineConfig) = sendPipelineResponseConfig;
imageXDoc = new System.Xml.XmlDocument();
//imageXDoc(BTS.SendPipelineResponseConfig) = @”<Root xmlns:xsd=””http://www.w3.org/2001/XMLSchema“” xmlns:xsi=””http://www.w3.org/2001/XMLSchema-instance””><Stages><Stage CategoryId=””9d0e4108-4cce-4536-83fa-4a5040674ad6″”><Components><Component Name=””DSL.BizTalk.PipelineComponents.ExtractImage””><Properties><rootPathExcel vt=””8″”>C:\Temp\Excel2\</rootPathExcel><rootPathImage vt=””8″”>C:\Temp\Image2\</rootPathImage></Properties></Component></Components></Stage></Stages></Root>”;

///This does not work. See http://blogs.objectsharp.com/cs/blogs/matt/archive/2006/10/09/dynamically-configuring-pipeline-component-properties-in-a-biztalk-orchestration.aspx
//imageXDoc(BTS.ReceivePipelineConfig) = sendPipelineResponseConfig;
//imagePipeline = Microsoft.XLANGs.Pipeline.XLANGPipelineManager.ExecuteReceivePipeline(typeof(OrchestrationCall2PipelineTest.RcvExtractImage),xDoc);
//imagePipeline.MoveNext();
//imagePipeline.GetCurrent(imageXDoc);

//This does not work either
imageXDoc(BTS.SendPipelineConfig) = sendPipelineResponseConfig;
imageXDoc(BTS.SendPipelineResponseConfig) = sendPipelineResponseConfig;
ExtractPipelineInput.Add(xDocCopy);
Microsoft.XLANGs.Pipeline.XLANGPipelineManager.ExecuteSendPipeline(typeof(OrchestrationCall2PipelineTest.SendExtractImage),ExtractPipelineInput,imageXDoc);

imageXDoc(FILE.ReceivedFileName) = System.IO.Path.GetFileNameWithoutExtension(xDoc(FILE.ReceivedFileName)) + imageXDoc(OrchestrationCall2PipelineTest.imageExtension);

containsImage = imageXDoc

I don’t think it is possible to do this. If you know how please drop me a line.

turbo360

Back to Top