cancel
Showing results for 
Search instead for 
Did you mean: 

how to clear model node input table data?

Former Member
0 Kudos

hi experts,

i am developing one application, which updates database table. i am having one table having all claimids as column, in of view. when i click on any of the claimid, it moves to second details view of that claim id having header and item details in seperate two tables on view.right. that second view is having addrow, deleterow and save button .

what i am facing problem is : when i add any row it works, delete any row it works and modify item details and save it , it works first time perfectly . bt when second time, i click on same claimid from first view and comes to details view and make any changes in item table and try to save it, it should save whatever is there at that time on table. Bt it takes new item values and as well as old one , all the time.

In backend , i passed that table and claimid and what i do , i delete all the item details with that claimid and insert new one . backend works fine.

I have disconnect the model instance as well....

wdContext.currentZbapi_Gen_Clm_Write_InputElement().modelObject().modelInstance().disconnectIfAlive();

any idea?

Plz.

Saurin Shah

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

by self solved through invalidate method...

former_member192434
Active Contributor
0 Kudos

Hi Saurin,

It seems that context node value not been clear out.

try to invialidate your node before submitting(Saveing) new value to context node On your details view scrren,.

NodeName().Invalidate();

or

for(int i=NodeName().size(); i++){

NodeName.removeElement( NodeName .getElementAt(i));

}

Thanks

Anup

Former Member
0 Kudos

Hi,

to clear node use the following code,

IPrivate<name>View.I<rfc node name>Node i<>Node = wdContext.node>rfc node name>Search();

for (int i = i<>Node .size(); i > 0; i--) {

i<>Node .removeElement( i<>Node .getElementAt(i - 1));

}

Regards,

ramesh

Former Member
0 Kudos

HI

wdcontext.node<modelinputnode>.invalidate();

where modeinputnode is the input node of ur bapi.

Regards,

Satya.