It is difficult to say. From the helperclass try writing the
xmldocument.OuterXml to a file and attach it to your post along with
the xpath query. Maybe someone can help you.
--
eliasen, representing himself and not the company he works for.
Private blog: http://blog.eliasen.dk
Private email: j...@eliasen.dk
START XML DOCUMENT>>
<?xml version="1.0" encoding="utf-8"?><ns3:order
xmlns:ns1="http://www.foofoo.org/ord/schemas/history"
xmlns:ns3="http://www.foofoo.org/schemas/ord/orderdesk"
xmlns:ns4="http://www.foofoo.org/schemas/ord/element"
xmlns:ns2="http://www.foofoo.org/schemas/ord/modul/orderdesk"
xmlns:ns0="http://www.foofoo.org/schemas/ord/header"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><flowMessageType>0uief06e-76f7-4e7c-abd7-38ce5eb24141</flowMessageType><flowIdentifier>42d65d57-47f5-4c43-9388-4ec3bc637d04</flowIdentifier><ns0:header><orderStatus>provisioning</orderStatus><orderDate>2006-10-10T12:53:12.052+02:00</orderDate><orderIdentifier></orderIdentifier><customer><customerIdentifier>201</customerIdentifier><customerName></customerName>
</customer></ns0:header><moduls><ns2:modul
modulOrderIdentifier="1344f31b-a500-d3355-9ef9-996987bdd2e"><modulIdentifier>101</modulIdentifier><name>New
Collection</name><description></description><price>0</price><supplier></supplier><dateSLA>2006-11-24T00:00:00+01:00</dateSLA><language>DE</language><employee><employeeIdentifier>3101</employeeIdentifier><employeeName>Sheng
Whuu</employeeName>
</employee><location><locationIdentifier>225</locationIdentifier><city></city><zip></zip><street></street><streetNbr></streetNbr><country>GB</country>
</location><elements><ns4:element elementOrderAction="add"
elementOrderIdentifier="6f1efd78-1591-49cf-8e5d-e2ecb7238499"><elementIdentifier>12901</elementIdentifier><supplier>IT</supplier><manufacturer></manufacturer><name>Levis
501 small
fit</name><description></description><itemPrice>0</itemPrice><amount>0</amount><parameters><parameter><key>Artikelbezeichnung</key><value></value>
</parameter>
</parameters>
</ns4:element><ns4:element elementOrderAction="add"
elementOrderIdentifier="85nd36be-3d63-4e08-ccfa-c27f9e86182d"><elementIdentifier>13601</elementIdentifier><supplier>IT</supplier><manufacturer></manufacturer><name>Levis
T-Shirt
406</name><description></description><itemPrice>0</itemPrice><amount>0</amount><parameters><parameter><key>Artikelbezeichnung</key><value></value>
</parameter>
<parameter>
<key>ProductID</key>
<value>2390945</value>
</parameter>
</parameters>
</ns4:element><ns4:element elementOrderAction="add"
elementOrderIdentifier="bkk316be-t03a-663d-rr4-h86f20z7c558"><elementIdentifier>14401</elementIdentifier><supplier>IT</supplier><manufacturer></manufacturer><name>Otpical
Scroll
Mouse</name><description></description><itemPrice>0</itemPrice><amount>0</amount><parameters><parameter><key>Artikelbezeichnung</key><value></value>
</parameter>
</parameters>
</ns4:element><ns4:element elementOrderAction="add"
elementOrderIdentifier="56be607d-397e-de73-9294-f32dr7e120f7"><elementIdentifier>13801</elementIdentifier><supplier>IT</supplier><manufacturer></manufacturer><name>Levis
Leather belt
red</name><description></description><itemPrice>0</itemPrice><amount>0</amount><parameters><parameter><key>Artikelbezeichnung</key><value></value>
</parameter>
</parameters>
</ns4:element></elements></ns2:modul></moduls></ns3:order>
<< END XML DOCUMENT
START XPATH QUERY>>
/*[local-name()='order' and
namespace-uri()='http://www.foofoo.org/schemas/ord/orderdesk']/*[local-name()='moduls'
and namespace-uri()='']/*[local-name()='modul' and
namespace-uri()='http://www.foofoo.org/schemas/ord/modul/orderdesk']/*[local-name()='elements'
and namespace-uri()='']/*[local-name()='element' and
namespace-uri()='http://www.foofoo.org/schemas/ord/element'][@elementOrderIdentifier='85nd36be-3d63-4e08-ccfa-c27f9e86182d']/*[local-name()='parameters']/*[local-name()='parameter'][key='ProductID']/*[local-name()='value']/text()
<< END XPATH QUERY
Jan Eliasen schrieb:
>Below is my xml doc and the xpath query expression, which always gives
>me a valid return value, when called from the WinForm client or from an
>xml xpath query tool. But running this xpath query in Biztalk inside my
>c# helper class i got XpathNodeIterator.Count =0.
Right. Well, if the XPAth always returns valid results when run
outside the orchestration, then my best beet would be that the
instance inside the orchestration is erroneous (spelling?). ave you
tried debugging your orchestration, setting a breakpoint just before
the shape where the xpath expression is used? And have you then
valdated that the message has in fact the correct content that matches
the xpath query?
Any idea would highly appreciated !
>Any idea would highly appreciated !
I am out of ideas. If you email me your project, I can take a look at
it. Should you email me, please refer to this thread in your email, so
I can find the description of your issue easier.
/*[local-name()='order']/*[local-name()='moduls']/*[local-name()='modul']/*[local-name()='elements']/*[local-name()
=
'element'][@elementOrderIdentifier='85nd36be-3d63-4e08-ccfa-c27f9e86182d']/*[local-name()='parameters']/*[local-name()='parameter'][key='ProductID']/*[local-name()='value']
Also, check the ElementFormDefault property of your schema. Is it
Qualified or not?
Change:
local-name()='parameter'][key='ProductID']
To:
*[local-name() = 'parameter'][*[local-name() = 'key']='ProductID']
rclb schrieb:
Very nice site! Good work. http://www.sessit.port5.com
BizTalk Utilities - Frustration free BizTalk Adapters
http://www.topxml.com/biztalkutilities
Nice design, good graphical content. I think I'll come back later again;) http://phentermines.forum-on.de
Du musst ein Fachmann sein - wirklich guter Aufstellungsort, den du hast! http://www.paradistc.org/liberi
Chi ha fatto questo? E un buon posto per trovare le informazioni importanti!:) http://www.sanzkdni59.org/formula-1
Lavoro eccellente! ..ringraziamenti per le informazioni..realmente lo apprezzo: D http://www.sanzkdni59.org/del-piero
Du musst ein Fachmann sein - wirklich guter Aufstellungsort, den du hast! http://www.circumno3.org/guerra
L'information interessante que vous avez! I'am allant revenir bientot. http://www.qukeartiere90.org/valentino-rossi