Uploaded image for project: 'Axis-C++'
  1. Axis-C++
  2. AXISCPP-420

Unknown Exception occures when 3 child elements are added to a Header Block

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • None
    • Client - Handlers
    • None
    • Windows

    Description

      I tried to add 3 child elements to a header block of a client handler.
      Then I got the "Unknown Exception has occured" error message but the output can be seen in the TCP Monitor.

      The following is the code that I added:-

      IHandlerSoapSerializer* pISZ;
      pIMsg->getSoapSerializer(&pISZ);

      IHeaderBlock* pIHeaderBlock= pISZ->createHeaderBlock();

      pIHeaderBlock->setLocalName("AddressDetails");
      pIHeaderBlock->setUri("http://soapinterop.org/echoheader/");

      //----------------------

      const AxisChar* pachHeaderVal = "no";

      BasicNode* pBasicNode = pIHeaderBlock->createChild(ELEMENT_NODE);
      pBasicNode->setLocalName(pachHeaderVal);

      pIHeaderBlock->addChild(pBasicNode);

      const AxisChar* pachHeaderVal1 = "239";

      BasicNode* pBasicNode1 = pIHeaderBlock->createChild(CHARACTER_NODE);
      pBasicNode1->setValue(pachHeaderVal1);

      pBasicNode->addChild(pBasicNode1);

      //---------------end----------

      //----------------------

      BasicNode* pBasicNode2 = pIHeaderBlock->createChild(ELEMENT_NODE);
      pBasicNode2->setLocalName("Lane");

      pIHeaderBlock->addChild(pBasicNode2);

      BasicNode* pBasicNode3 = pIHeaderBlock->createChild(CHARACTER_NODE);
      pBasicNode3->setValue("2nd Lane");

      pBasicNode2->addChild(pBasicNode3);

      //--------------end-----
      //----------------------

      BasicNode* pBasicNode4 = pIHeaderBlock->createChild(ELEMENT_NODE);
      pBasicNode4->setLocalName("City");

      pIHeaderBlock->addChild(pBasicNode4);

      BasicNode* pBasicNode5 = pIHeaderBlock->createChild(CHARACTER_NODE);
      pBasicNode5->setValue("sfgsgsg");

      pBasicNode4->addChild(pBasicNode5);

      //-------end---------

      }

      Attachments

        Activity

          People

            rangika Rangika Mendis
            rangika Rangika Mendis
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: