Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Problem regarding the node is not Invalidating

Hi i am using following code but not getting refreshed value when i call bapi again;

1.wdInit

input = new Ztrip_Expense_Vendor_Invoice_Input(WDModelScopeType.TASK_SCOPE);

2.inserting data

try

{

//add all simple ele

input = new Ztrip_Expense_Vendor_Invoice_Input();

input.setInvoice_Date(iDate);

input.setInvoice_Number(invoiceNumber);

input.setName(name);//whose name

input.setTotal_Amount(total);

input.setTrip_Id(cabTripId);

input.setVendor(vendorCode);

//send table

Zcab_Vendor_Payment_Stru2 table;

// //clear itemnode

// wdContext.nodeZtrip_Expense_Vendor_Invoice_Input().nodeOutput5().nodeItem_Data().invalidate();

// //clear msg node

// wdContext.nodeZtrip_Expense_Vendor_Invoice_Input().nodeOutput5().nodeMessage5().invalidate();

//

//get value form node assing to item node

for(int k=0;k<wdContext.nodeSendDetails().size();k++ )

{

table= new Zcab_Vendor_Payment_Stru2();

int amt = wdContext.nodeSendDetails().getSendDetailsElementAt(k).getAmounts();

String amount = String.valueOf(amt);

table.setAmount(amount);

table.setCost_Center(wdContext.nodeSendDetails().getSendDetailsElementAt(k).getCostCenter());

table.setGl_Account(wdContext.nodeSendDetails().getSendDetailsElementAt(k).getGlAccount());

table.setTax_Code(wdContext.nodeSendDetails().getSendDetailsElementAt(k).getTaxCode());

input.addItem_Data(table);

wdControllerAPI.getMessageManager().reportSuccess("gl acc in senddetails node:"+wdContext.nodeSendDetails().

getSendDetailsElementAt(k).getGlAccount());

}

//execute model

wdContext.nodeZtrip_Expense_Vendor_Invoice_Input().bind(input);

//wdContext.currentZtrip_Expense_Vendor_Invoice_InputElement().modelObject().execute();

input.execute();

wdContext.nodeZtrip_Expense_Vendor_Invoice_Input().nodeOutput5().invalidate();

wdContext.nodeZtrip_Expense_Vendor_Invoice_Input().nodeOutput5().nodeItem_Data().invalidate();

wdContext.nodeZtrip_Expense_Vendor_Invoice_Input().nodeOutput5().nodeMessage5().invalidate();

}//try

catch (WDDynamicRFCExecuteException e)

{

//to do block deleted

e.printStackTrace();

}//catch

Former Member
Not what you were looking for? View more on this topic or Ask a question