cancel
Showing results for 
Search instead for 
Did you mean: 

Removing the elements from table

Former Member
0 Kudos

Hi Friends,

I am working on tables in webdynpros. I need to remove the all of the rows from table, I am using the following statement but it is not working for me.

wdContext.nodeWorkLocation().removeElement();

Could you please tell me the way to remove all the rows from a table.

I am waiting for your positive response.

Thanks and Regards,

Sandeep Kumar B.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Sandeep,

Use

wdContext.nodeWorkLocation().bind((Collection) null);

Bala

Former Member
0 Kudos

Hi Bala,

Thank you for responding quickly to my query. You have given a solution as binding the null object to table node, But solution donen't make any effect to the existing data in table. Because we are just trying to bind new object to the existing data. Anyway thank you for giving reply.

Could you please find the another solution for this.

Thank you,

Sandeep Kumar B.

Former Member
0 Kudos

Hi

Try this

wdContext.node<Table>().invalidate();

Kind Regards

Mukesh

Former Member
0 Kudos

Hi Mukesh,

I tried with invalidate() method but still I'm not able to remove the elements from table.

Thank you,

Sandeep Kumar B

Former Member
0 Kudos

hi

try like this one by one.

size = wdContext.node<table>.size;

for(int i=(size-1);i >=0;i--)

{

wdContext.nodename().removeElement(wdContext.nodename().getElementAt(i));

}

thanks

Lohi.

Answers (0)