creating a new message in the Message Assign shape

Home Page Forums BizTalk 2004 – BizTalk 2010 creating a new message in the Message Assign shape

Viewing 6 reply threads
  • Author
    Posts
    • #20511

      Hello,

       

      I must send a response message (status code and text) from inside of a web service to the WS client.

       

      This message must be created/constructed inside of the orchestrion. A schema (the received data uses another schema) is created for this and the fields I have to fill are marked as distinguished.

       

      The only samples I found  for inside of the Message Assignment shape are to assign “msgOut = msgIn” and then changing some properties or distinguished fields. But this works only if both messages are using the same schema.

       

      My code (in the Message Assign shape) looks like following:

                  msgOut.MsgPart1.ErrorCode = “4711”;

                  msgOut.MsgPart1.ErrorMsg = “some text message”;

       

      and in the properties “Message Create” the msgOut messages is selected.

       

      During the compilation I get:

                  Message part has not been inialized in construct statement

       

       

      I don’t what to do! Can you please give me some help?

       

      Best regards

      Hermann

       

    • #20514

      Hi Hermann,

      Here are a few ways you could initialize the message:

      1.  With a map.  This is a good technique if you need to pull data from another message, but doesn’t make that much sense if you are just hardcoding values.

      2.  With a helper class.  Use XSD.exe to generate a class to represent the schema.  Then write a helper class to instantate and return the class representing your schema.  Call the helper class from a message assignment and assign the output to your return message.  This is the “right” way to do it in my opinion, although it is kind of a pain to set up.

      3.  Use XmlDocument.LoadXml to initialize the message.  You need to create an extra message of type XmlDocument.  Then in the message assignment:

      xmlDocMessage = new System.Xml.XmlDocument();

      xmlDocMessage.LoadXml(“<Out><ErrorCode>4711</ErrorCode></Out>”);

      msgOut.MsgPart1 = xmlDocMessage;

      This method is very quick and effective, but it makes you feel kind of dirty 🙂

      4.  There is some easy way to do it using the “xpath()” function, but I don’t remember how.  Maybe someone can fill us in!

    • #20580

       Is this statement part of the message assignment shape?

      msgOut.MsgPart1 = msgIn

    • #37422
      Quammaabene

        Fischer was Professor of Clinical Pharmacy Practice and Consultant for the Division of General Internal Medicine at the University of Mississippi Medical Center.What are the etiquette rules one should have during a funeral? What you are wearing should not attract any attention to you. Homberger died in 1955. Cheap NFL Jerseys Wholesale.A whole lot of IWC’s iconic view models and technical breakthroughs had been born throughout this interval. Talking with your mouth full with food says a lot about you. Hornberger, Esq.Jimmy Choo Footwear It truly is an fantastic time to shell out money on an entire newMerle Kilger   Submitted 2012-03-28 15:27:52 Are all of your family customers all across the search which includes as much as the minute design hair manufacturer name for much more information about reinforce your be for the lookout This time you may possibly find a way to obtain extra concepts about varied forms with a bit aid from hair professionals.You can include one/4 or one/3 part aloe juice to a cup of apple juice to make the flavor simpler to manage. While the idea of two warring spouses engaging in calm, productive conversations that lead to workable solutions for everyone is foreign to many people, the process saves time, money and frustration for those willing to participate.Rafaello OliveiraThis is the fastest growing sport in the world.Wholesale Jerseys From China. Established in 2005 and incorporated as Private Limited Company in 2008, LCS® is a leading global language solutions provider, enabling companies to enter global markets with high quality multilingual products.Cheap NFL Jerseys From China. It basically raises images of high-class society meetings and unsaid rules of behavior.<br>Visit my site?http://www.cheapnflfootballjerseysauthentic.us.com/

      • #37423
        MumelewmexT

          On the bright side, business signage are here to stay. Cheap Jerseys Store.Our skilled translation services stretch across a number of various needs, therefore we have a tendency to are exceptionally well-equipped to serve you. They ran IWC as an open up trading company with the name in the Uhrenfabrik Von J. You must take care in the caterers you choose. He made a fresh premise towards the authentic manufacturing unit, purchased new machines,Cheap Nike NFL Jerseys China Wholesale, and set up modern pension fund for the staff.When you start making calls to get someone to help with your HVAC system, it’s a good idea to know what system you have before that phone call. Successfully Exiting the MarriageTraditional divorce litigation models, in particular contested divorces and cases involving abuse or endangerment, usually mean there are winners and losers when the judge issues the final decree of divorce. It’s a Terrific concept, an inexpensive instrument that this making an attempt in direction of help you save your financial. You receive your own website, which you can use for whatever you wish. At times, your location of business can be mapped on Google.Cheap Nike NFL Jerseys.A whole lot of IWC’s iconic view models and technical breakthroughs had been born throughout this interval. You have chosen the perfect venue.<br>Visit my site?http://www.cheapnflchinajerseyswholesale.us.com/

        • #37581
          Robertgok

            It’s time to buy that new grille, and did you know that by purchasing a custom one you’re doing more than making your truck look like the meanest ride on the block?Picture This…You’re driving along minding your own business. One thing that is important to comprehend is these are a protected spot to do any sort of chase. These are –Thermoformed Polyethylene Canoes, Cheap NHL Jerseys, Polylink 3 Canoes, Royalex Canoes and the Sporting Canoes.Phone bills are quite usefull.You can explain that you need to open a bank account. Ultimately, when this botanical is used to treat such animals, the outcome is generally satisfactory.There are millions of couples living together right now that are happy and in love and simply feel no need to prove those things with a wedding or a marriage.Most of the girls all summer like to wear Japanese fashion dresses,Wholesale NHL Jerseys, especially this summer print dress popular, is to become one of the girls favorite single product. This is because research has shown that the plant is very effective when used to treat a variety of canines disorders.Small round neck chiffon shirt of Japanese fashion, never off the stereotypes, coupled with a yellow lace waist dress, the taste of OL style!Let the wind snatched away all of your displeasure in the face of nature, not as good as people are actually small even a dust, the journey of life, everywhere full of the temptation of the substance, the only constant is your heart. In situation of any misunderstandings, you can contact the customer service or you can hire their professional help to set things up for you.Cheap NHL Jerseys China. 21 (Xinhua) — The 54th Cuban National Series, the main baseball tournament on the island, began on Sunday with the game between Matanzas and Pinar del Rio.<br>Visit my site?http://www.cheapnhlmall.com/

          • #37719
            bracciali cartier imitazione

              As a non-Christian, I’m okay when Christians pray for me. It’s positive energy directed at me, going into the universe.
              bracciali cartier imitazione http://www.clovejs.ru/it/cartier-love-bracelet-replica-c134/

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