Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

How to copy values from multiple table rows into text field?

Avatar

Avatar
Validate 10
Level 2
aka44356106
Level 2

Likes

10 likes

Total Posts

56 posts

Correct Reply

0 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile

Avatar
Validate 10
Level 2
aka44356106
Level 2

Likes

10 likes

Total Posts

56 posts

Correct Reply

0 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile
aka44356106
Level 2

01-10-2019

Sir i have a new query

in a dynamic form add instance create multiple row by click a button

Table4._Row1.addInstance(0);

value of Table4.Row1(0).cell1.rawvalue, Table4.Row1(1).cell1.rawvalue, ............

can be copy in a textfield?

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Coach
MVP
radzmar
MVP

Likes

397 likes

Total Posts

2,687 posts

Correct Reply

492 solutions
Top badges earned
Coach
Ignite 3
Ignite 1
Validate 1
Give Back 50
View profile

Avatar
Coach
MVP
radzmar
MVP

Likes

397 likes

Total Posts

2,687 posts

Correct Reply

492 solutions
Top badges earned
Coach
Ignite 3
Ignite 1
Validate 1
Give Back 50
View profile
radzmar
MVP

06-10-2019

Well, the accessor names are all case-sensitive, so you may have to correct them.

Try:

  1. var oCells = Table4.resolveNodes("Row1.[Cell1 ne null]"), // Reference all instances of Row1, where Cell1 is not null 
  2.     cResult = "", // the output string 
  3.     i; // a count variable 
  4.  
  5. for (i = 0; i < oCells.length; i += 1) { 
  6.     cResult += oCells.item(i).Cell1.rawValue + " "; // Add rawValue of each filled cell to the output string. 
  7. this.rawValue = cResult;

Answers (4)

Answers (4)

Avatar

Avatar
Validate 10
Level 2
aka44356106
Level 2

Likes

10 likes

Total Posts

56 posts

Correct Reply

0 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile

Avatar
Validate 10
Level 2
aka44356106
Level 2

Likes

10 likes

Total Posts

56 posts

Correct Reply

0 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile
aka44356106
Level 2

09-10-2019

sir i want cResult in these formats

1. when instant manager count is 1

cResult outout is    Table4.Row1.cell1.rawvalue

2. when instant manager count is 2

cResult outout is    Table4.Row1[0].cell1.rawvalue + "and" +  Table4.Row1[1].cell1.rawvalue

3. when instant manager count is more than 2

cResult outout is    Table4.Row1[0].cell1.rawvalue + "," +  Table4.Row1[1].cell1.rawvalue + "and" + Table4.Row1[2].cell1.rawvalue

simply output will be  

instant manager count    = 1                             A

instant manager count    = 2                             A and B

instant manager count    = 3                            A, B, and C

instant manager count    = 4                            A, B, C and D

...........................

             

Avatar

Avatar
Validate 10
Level 2
aka44356106
Level 2

Likes

10 likes

Total Posts

56 posts

Correct Reply

0 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile

Avatar
Validate 10
Level 2
aka44356106
Level 2

Likes

10 likes

Total Posts

56 posts

Correct Reply

0 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile
aka44356106
Level 2

08-10-2019

Good its working

Avatar

Avatar
Validate 10
Level 2
aka44356106
Level 2

Likes

10 likes

Total Posts

56 posts

Correct Reply

0 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile

Avatar
Validate 10
Level 2
aka44356106
Level 2

Likes

10 likes

Total Posts

56 posts

Correct Reply

0 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile
aka44356106
Level 2

02-10-2019

Error : accessor 'cell1' is unknown

Avatar

Avatar
Coach
MVP
radzmar
MVP

Likes

397 likes

Total Posts

2,687 posts

Correct Reply

492 solutions
Top badges earned
Coach
Ignite 3
Ignite 1
Validate 1
Give Back 50
View profile

Avatar
Coach
MVP
radzmar
MVP

Likes

397 likes

Total Posts

2,687 posts

Correct Reply

492 solutions
Top badges earned
Coach
Ignite 3
Ignite 1
Validate 1
Give Back 50
View profile
radzmar
MVP

01-10-2019

To collect the text values of multiple rows, use a for loop.

var oCells = Table4.resolveNodes("Row1.[cell1 ne null]"), // Reference all instances of Row1, where cell1 is not null

    cResult = "", // the output string

    i; // a count variable

for (i = 0; i < oCells.length; i += 1) {

    cResult += oCells.item(i).cell1.rawValue + " "; // Add rawValue of each filled cell to the output string.

}

this.rawValue = cResult;