Selecting Data from a Repeating Table that is Bound to Data Connec

M

MWPais

Hi,

I am trying to retrieve data from a repeating table that is bound to a data
connection.

When I look at my data source in the task pane I see the following:

-myFields
-dataFields
-d:product_List
:productCode
:Description

I need my script to return the ProductCode and Description.

I am trying to use XDocument.DOM.selectSingleNode to extract the data but I
am having trouble formatting the xpath string for the retrieval. Below is a
line from my script:

var myProductCode =
XDocument.DOM.selectSingleNode("/my:myFields/my:dataFields/my:product_List[position()]");

If anyone can correct this line I would greatly appreciate it. Thanks.
 
S

Swathi (GGK Tech)

Hi,

In your xpath you are using my as name space. Once verify the name space for
the dat secondary connection. And if you want the product code then use the
following code line.
var myProductCode =
XDocument.DOM.selectSingleNode("/my:myFields/my:dataFields/my:product_List[position()]/my:productCode");
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top