Geeks With Blogs

You created classes from your XML-Schemas (using XSD.exe for example) and want to use them in BizTalk. There may be several reasons for and against doing it. But I do not want to discuss that here. Just assume you want to do it. ;-)

After you deployed your BizTalk App and start sending the first messages to your ReceiveLocation with an XML Receive Pipeline of a MessageType that a schema and a class exist for. BizTalk is not able to decide whether  class or schema should be used and  gives you a nice error in the event log: 

There was a failure executing the receive pipeline: "Microsoft.BizTalk.DefaultPipelines.XMLReceive, .....

 Reason: Cannot locate document specification because multiple schemas matched the message type http://myschema...#Order.


When you have a look at the schemas in the BTS-Admin-Console you discover that you have two Schemas listed there with identical namespaces and root-names, resulting in identical MessageTypes.

To show BizTalk which Assembly it should use you can use the property "DocumentSpecNames" in the configuration of the XMLReceive Pipeline of your ReceiveLocation. Just type or paste the full strongname of the Assembly and the type that should be used, e.g. MySchemas.Schemas.Order, Schema.Order, Version=, Culture=neutral, PublicKeyToken=88c5c240c6b0ed6f.

Please ignore the namespaces in my post. They are just for demonstration... ;-)


Posted on Friday, June 25, 2010 9:54 AM BizTalk | Back to top

Comments on this post: Using Schema and Serialization Classes in BizTalk

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

Copyright © mipsen | Powered by: