Set value to Element in a message using xpath

Home Page Forums BizTalk 2004 – BizTalk 2010 Set value to Element in a message using xpath

Viewing 1 reply thread
  • Author
    Posts
    • #22379

      Am trying to set value of a element in messageAssignment shape using xpath

      xpath(IntegrationOrder,
      “//*[local-name()=’IntegrationOrderInfo’][1]/*[local-name()=’IntegrationOrderId’][1]”) = TransmissionId

      IntegrationOrderId is lnt64
      TransmissionId = Int64
      Everything is minoccurs = 0 maxoccurs =1

      Getting the following error

      selected a node which is not valid for property or distinguished field
      retrieval, or it selected no node at all. Only text-only elements or
      attributes may be selected.
             
      Exception type: XPathSelectionException
      Source: Microsoft.XLANGs.Engine
      Target Site: Void XPathStore(System.Object, System.String)
      The following is a stack trace that identifies the location where the
      exception occured

         at Microsoft.XLANGs.Core.Part.XPathStore(Object rValue, String xpath)
         at testbits.test.segment2(StopConditions stopOn)
         at Microsoft.XLANGs.Core.SegmentScheduler.RunASegment(Segment s,
      StopConditions stopCond, Exception& exp)


      Thanks

    • #22398

      Possible causes:
      1. The element does not exist in the message. The xpath function will not create an element if it does not exist.
      2. The xpath statement cannot be resolved. Do you have an sample message?

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