Assigning values to properties in property schemas

Home Page Forums BizTalk 2004 – BizTalk 2010 Assigning values to properties in property schemas

Viewing 1 reply thread
  • Author
    • #12840

      How do you assign values to properties of property schemas from other messages (Header Message which is using a simple schema)

      Next How do you extract these assigned values from property schemas in the orch ? Any helpful xlang?

    • #12841

      I hope I understand your question – you are asking how the basics of promoted fields, correct?

      Make sure you are in a \”MessageAssignment\” shape – i.e. you are constructing a new message if you want to set the value of a message on the left of the equal sign.

      msgout(TestSchema.PropertySchema.CustomerId) = msgin(TestSchema.PropertySchema.CustomerId);

      If you just need to set a variable, you don’t need to be in a \”MessageAssignment\”:

      myString = msgin(TestSchema.PropertySchema.CustomerId);

      When you type the parentheses after the message-name, intellisense should give you a list of promoted fields. Just scroll down to your project’s namespace.

      If you are using distinguished fields, the syntax is quite different:

      msgout.CustomerId = msgin.CustomerId;

      You might have to do a build once to get the intellisense to work.

      You can also use the xpath statement as an alternative, so in this example if have a distinguished field on the left, but I’m using xpath on the right.

      msgout.CustomerId = xpath(msgin,\”string(//Order/CustomerNumber)\”);

      Xpath can also be used on the left side of the equals sign.

      Neal Walters

Viewing 1 reply thread
  • The forum ‘BizTalk 2004 – BizTalk 2010’ is closed to new topics and replies.