cancel
Showing results for 
Search instead for 
Did you mean: 

table with multiple input fields

Former Member
0 Kudos

Hi experts!!

I am trying to create a table UI element with all columns as input fields.

While running the application, i can only enter values for one row.

I have set the selection mode to multi, but still no difference..

Any ideas???

Thanx in advance!!!!

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Ok!! I understand both your replies..

But what if i do not know at design time the exact number of elements added???

Former Member
0 Kudos

Hi,

you use -

wdContext.node<node name>.size()

Aviad

PradeepBondla
Active Contributor
0 Kudos

Hi,

Yes, Levy is right.

get the size of the node and loop it that many times.

PradeeP

Former Member
0 Kudos

Hi,

Have a "Add" button in your view. On click of this add create the element so that user can enter the details. In this way you dont need to know the size of the elements to be created.

Hope this helps.

thanks & regards,

Manoj

Answers (5)

Answers (5)

Former Member
0 Kudos

Thank you all for your replies!!!

Problem solved!!

PradeepBondla
Active Contributor
0 Kudos

Hi,

check the Armin's suggestions in this thread

https://www.sdn.sap.com/irj/sdn/thread?threadID=59210

if the node is employee under which you have name, surname and age.... create as many elements of inputfields as you want. if you want 5 rows, and you have 3 elements so 5*3=15 times you have to loop

for (int i = 0; i < 15; ++i)
{
  IEmployeesElement e = wdContext.nodeEmployees().createEmployeesElement();
  wdContext.nodeEmployees().addElement(e);
}

PradeeP

Former Member
0 Kudos

There are 3 elements: name, surname, age.

I can enter those elements only for one line(row). (e.g. Iria Koutsogianni 23) i try to select another line to enter values to, but i cannot.

Former Member
0 Kudos

Hi,

These (name, surname, age) are attributes not elements.

My guess that you have only one element which is predefined (because of the cardinality was set to 1..n).

In order to add rows you need to add an action (button or toolbar button) which adds a new row (element) to the table (node).

Aviad

Former Member
0 Kudos

Actually it is set to 1..n

Former Member
0 Kudos

Hi,

1..n is also good.

How many elements are in this node?

Can you select other rows?

Aviad

Former Member
0 Kudos

Hi,

Is the node which the table is based on is set to cardinality 0..n?

Aviad