Skip to Content
0
Former Member
Apr 26, 2009 at 04:43 AM

How to remove multiple rows from table

24 Views

Hi All,

in my application iam using two tables,

this is my code

int selection = wdContext.nodeA().getLeadSelection();

String num = wdContext.nodeA.geAAt(selection).getV_Num();

for(int b=0;b<wdContext.nodeVn_Context().size();b++)

{

if(wdContext.nodeVn_Context().getVn_ContextElementAt(b).getVa_num().equalsIgnoreCase

(num))

{

wdContext.nodeVn_Context().removeElement(wdContext.nodeVn_Context().getVn_ContextElementAt(b));

}

}

here Vn_Context is having 4 rows, i mean size of Vn_Context is 4. when i use this code to remove that 4 rows based on the condition, which i gave in if, its able to remove only one row, so how to remove those four rows, is this code correct or not, please help me.