Get row values from a Repeating Table

K

Kenneth Mora F.

Hi
I have a repeating table with n rows with data. Supose I make click in the
third row, can I get the values of that third row and copy them to text
controls?
Thans Kenneth
 
V

Victor

Yes you can.

var oRow1 =
XDocument.DOM.selectSingleNode("/my:myFields/my:group1/my:group2[1]");
var valueFromFirstRow = oRow1.selectSingleNode("my:field1").text;
var oRow2 =
XDocument.DOM.selectSingleNode("/my:myFields/my:group1/my:group2[2]");
var valueFromSecondRow = oRow2.selectSingleNode("my:field1").text;

var oRow3 =
XDocument.DOM.selectSingleNode("/my:myFields/my:group1/my:group2[3]");
var valueFromThirdRow = oRow3.selectSingleNode("my:field1").text;



Let's say your text field is field3:

XDocument.DOM.selectSingleNode("/my:myFields/my:field3").text=valueFromThirdRow

You should put them in one line.
 
K

Kenneth Mora F.

Hi Victor, thank you for your answer, but I got one more question... can I do
the same with C# using the changed event?

Kenneth

Victor said:
Yes you can.

var oRow1 =
XDocument.DOM.selectSingleNode("/my:myFields/my:group1/my:group2[1]");
var valueFromFirstRow = oRow1.selectSingleNode("my:field1").text;
var oRow2 =
XDocument.DOM.selectSingleNode("/my:myFields/my:group1/my:group2[2]");
var valueFromSecondRow = oRow2.selectSingleNode("my:field1").text;

var oRow3 =
XDocument.DOM.selectSingleNode("/my:myFields/my:group1/my:group2[3]");
var valueFromThirdRow = oRow3.selectSingleNode("my:field1").text;



Let's say your text field is field3:

XDocument.DOM.selectSingleNode("/my:myFields/my:field3").text=valueFromThirdRow

You should put them in one line.



Kenneth Mora F. said:
Hi
I have a repeating table with n rows with data. Supose I make click in the
third row, can I get the values of that third row and copy them to text
controls?
Thans Kenneth
 

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