Geeks With Blogs
MoonWalker Biztalk Driven Addiction

Sometimes I need to load a stream from a file in a Biztalk pipeline and I have to determine the Type of the message.

Here s how i do that :

// This is for sample only. Should refer to the message stream and rewind the stream

Stream fs = new FileStream(filepath, FileMode.Open); 

// End of stream initialisation.

XPathDocument sourceDoc = new XPathDocument(fs);

XPathNavigator navigator = sourceDoc.CreateNavigator();


string streamDocSchema = navigator.NamespaceURI + "#" + navigator.LocalName;

// Assigns the Namespace to the MessageType in context

Posted on Tuesday, May 17, 2011 5:16 PM Biztalk , .Net | Back to top

Comments on this post: XML Stream Namespace

No comments posted yet.
Your comment:
 (will show your gravatar)

Copyright © Frederic Hautecoeur | Powered by: