|
Home > Archive > BizTalk Server Orchestration > April 2006 > Is there a way to create a message without using an existing messa
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 |
Is there a way to create a message without using an existing messa
|
|
|
| Hi,
I have got such a problem, I have defined a message instance in
orchestration based on a message schema.
I send this message to disk. But I found I could not find a way to in
initialize.
I know we can use transform shape to create a message, but that requires an
already existing message to do mapping,
Also, I don't want to use external component to do the message creation.
So, the only way I think I can do is using the message assignment shape.
Then, in expression shape, I used expression like:
FaultMessage.id = 123;
where 'FaultMessage'is my defined message. and 'id' has been promoted in
the property schema.
The biztalk gives me such errors:
use of unconstructed message 'FaultMessage'
'FaultMessage': message has not been initialized in construct statement
Is there a way to create a message without using an existing message?
Thanks
| |
| carlos medina 2006-04-10, 7:32 pm |
| hi...
check this page
http://www.objectsharp.com/Blogs/ma...9/1009.aspx.... you
can find information about constructing messages...
regards !
"Frank" <Frank@discussions.microsoft.com> wrote in message
news:5C8114E8-BDE4-4AC6-BB49-AE9DC4846F33@microsoft.com...
> Hi,
>
> I have got such a problem, I have defined a message instance in
> orchestration based on a message schema.
>
> I send this message to disk. But I found I could not find a way to in
> initialize.
>
> I know we can use transform shape to create a message, but that requires
> an
> already existing message to do mapping,
>
> Also, I don't want to use external component to do the message creation.
>
> So, the only way I think I can do is using the message assignment shape.
>
> Then, in expression shape, I used expression like:
> FaultMessage.id = 123;
> where 'FaultMessage'is my defined message. and 'id' has been promoted in
> the property schema.
>
> The biztalk gives me such errors:
> use of unconstructed message 'FaultMessage'
> 'FaultMessage': message has not been initialized in construct statement
>
>
> Is there a way to create a message without using an existing message?
>
> Thanks
>
>
| |
| Gold E 2006-04-18, 12:46 am |
| Hi Frank,
My guess is that you have variables or some hard-coded value you would like
to assign to a new message, and hence have no source message to map the data
from. In this case, you could initialize/construct a message with the
following syntax within an expression shape:
construct msgToConstruct
{
msgToConstruct.AttributeA = varA;
msgToConstruct.AttributeB = "ValueB";
}
The construct keyword will operate as a construct message shape, but will
allow you to do so without mapping/transforming from a source message within
it.
Hope that helps!
"Frank" wrote:
> Hi,
>
> I have got such a problem, I have defined a message instance in
> orchestration based on a message schema.
>
> I send this message to disk. But I found I could not find a way to in
> initialize.
>
> I know we can use transform shape to create a message, but that requires an
> already existing message to do mapping,
>
> Also, I don't want to use external component to do the message creation.
>
> So, the only way I think I can do is using the message assignment shape.
>
> Then, in expression shape, I used expression like:
> FaultMessage.id = 123;
> where 'FaultMessage'is my defined message. and 'id' has been promoted in
> the property schema.
>
> The biztalk gives me such errors:
> use of unconstructed message 'FaultMessage'
> 'FaultMessage': message has not been initialized in construct statement
>
>
> Is there a way to create a message without using an existing message?
>
> Thanks
>
>
| |
| erithtotl@gmail.com 2006-04-18, 12:46 am |
| Gold E:
Do you use this in an expression shape or message assign? In a message
assign I get a compiler error (but no syntax issues). If I use it in
an expression, then I get a 'use of unconstructed message' in my send
shape, because the message was not initialized in a construct shape.
Note I'm using BizTalk 2006.
Thanks!
| |
| SaravananBiz 2006-04-27, 1:21 pm |
| Construction of message is something like assigning some valid xml to it. In
your case, lets assume that u get a message to trigger the orchestration and
u have another message pertaining to a schema which has to be sent to the
send port. The problem is to construct that message.(Hope I have understood
the problem correctly). This can be done like this.
1) Create a variable of type XMLDocument.
2) Assign the variable to the xml string of the message. i.e the instance of
the send message.
3) Have a message assignment shape, in which assign the variable to the
message.
This will construct the message.
"Frank" wrote:
> Hi,
>
> I have got such a problem, I have defined a message instance in
> orchestration based on a message schema.
>
> I send this message to disk. But I found I could not find a way to in
> initialize.
>
> I know we can use transform shape to create a message, but that requires an
> already existing message to do mapping,
>
> Also, I don't want to use external component to do the message creation.
>
> So, the only way I think I can do is using the message assignment shape.
>
> Then, in expression shape, I used expression like:
> FaultMessage.id = 123;
> where 'FaultMessage'is my defined message. and 'id' has been promoted in
> the property schema.
>
> The biztalk gives me such errors:
> use of unconstructed message 'FaultMessage'
> 'FaultMessage': message has not been initialized in construct statement
>
>
> Is there a way to create a message without using an existing message?
>
> Thanks
>
>
|
|
|
|
|