|
Home > Archive > BizTalk Server General > August 2005 > Error while assigning values to Distinguished Fields in a orchestration
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Error while assigning values to Distinguished Fields in a orchestration
|
|
| Pankaj 2005-08-31, 7:49 am |
| Hi,
I am using HTTP Solicit Response port to send an xml document over HTTP
inside an orchestration.
I am catching the System.Web.Services.Protocols.SoapException
exception inside a catch block.
After catching the exception, I am formulating an ERROR message using
distinguished inside a construct message shape.
xmlErrorMessage = new System.Xml.XmlDocument();
xmlErrorMessage.ERRORFILE = "Sample.txt";
xmlErrorMessage.ERRORMESSAGE = Ex.Message ;
However I am getting the following runtime error while assigning values to
the distinguished fields.
If I dont initialize the message using xmlErrorMessage = new System.Xml.
XmlDocument(), I cannot build the project and get an error
'xmlErrorMessage': message has not been initialized in construct statement
What is going wrong?
How do I solve this?
ERROR
Event Type: Error
Event Source: XLANG/s
Event Category: None
Event ID: 10034
Date: 8/31/2005
Time: 2:46:50 PM
User: N/A
Computer: BIZTALK
Description:
Uncaught exception terminated service Orch.
BizTalk_Orchestration1(6381cd74-97c5-0d6b-9635-079daa9b96e1), instance
f5470d88-250e-418a-b98c-947a0a1f130c
A failure occurred while evaluating the distinguished field ERRORFILE
against the message part data. The message part data does not contain at
least one of the nodes specified by the XPath expression (listed below) that
corresponds to the distinguished field. The cause for this error may be that
the message part data has not been initialized or that the message part data
does not conform to the message part schema. Ensure that the message part
data is initialized correctly.
XPath expression: /*[local-name()='ERROR' and namespace-uri()
='http://AventeonServiceOne.xmlErrorMessage']/*[local-name()='ERRORFILE' and
namespace-uri()='']
Exception type: XPathUpdateException
Source: Microsoft.XLANGs.Engine
Target Site: Void SetDistinguishedField(System.String, System.Object)
Help Link:
Additional error information:
| |
|
| Pankaj,
You need to initialize any message before you can set values in it
which can be done either by using maps or creating message explicitly
as you've done here.
You need to load the schema of xml in the object before you can use it
e.g
xmlErrorMessage.LoadXml("<ERRORFILE></ERRORFILE><ERRORMESSAGE></ERRORMESSAGE>");
and then assign values to it
Pankaj wrote:
> Hi,
>
> I am using HTTP Solicit Response port to send an xml document over HTTP
> inside an orchestration.
> I am catching the System.Web.Services.Protocols.SoapException
> exception inside a catch block.
> After catching the exception, I am formulating an ERROR message using
> distinguished inside a construct message shape.
>
> xmlErrorMessage = new System.Xml.XmlDocument();
> xmlErrorMessage.ERRORFILE = "Sample.txt";
> xmlErrorMessage.ERRORMESSAGE = Ex.Message ;
>
> However I am getting the following runtime error while assigning values to
> the distinguished fields.
>
> If I dont initialize the message using xmlErrorMessage = new System.Xml.
> XmlDocument(), I cannot build the project and get an error
> 'xmlErrorMessage': message has not been initialized in construct statement
>
> What is going wrong?
> How do I solve this?
>
> ERROR
>
> Event Type: Error
> Event Source: XLANG/s
> Event Category: None
> Event ID: 10034
> Date: 8/31/2005
> Time: 2:46:50 PM
> User: N/A
> Computer: BIZTALK
> Description:
> Uncaught exception terminated service Orch.
> BizTalk_Orchestration1(6381cd74-97c5-0d6b-9635-079daa9b96e1), instance
> f5470d88-250e-418a-b98c-947a0a1f130c
>
> A failure occurred while evaluating the distinguished field ERRORFILE
> against the message part data. The message part data does not contain at
> least one of the nodes specified by the XPath expression (listed below) that
> corresponds to the distinguished field. The cause for this error may be that
> the message part data has not been initialized or that the message part data
> does not conform to the message part schema. Ensure that the message part
> data is initialized correctly.
> XPath expression: /*[local-name()='ERROR' and namespace-uri()
> ='http://AventeonServiceOne.xmlErrorMessage']/*[local-name()='ERRORFILE' and
> namespace-uri()='']
>
> Exception type: XPathUpdateException
> Source: Microsoft.XLANGs.Engine
> Target Site: Void SetDistinguishedField(System.String, System.Object)
> Help Link:
> Additional error information:
| |
| Pankaj 2005-08-31, 7:49 am |
| Thanks a lot Vishy
That Solves all my troubles.
Pankaj
|
|
|
|
|