Skip to Content
0
Former Member
Oct 21, 2005 at 05:35 AM

wdContext.validate() not working!!!!!!!!!!!!!

21 Views

hi

When i go from one view to other view on click of "submit" button, the 2nd view shows the detail of orders.

The problem is on click of "back" button when i go to 1st view and give the other date range and press "submit"

button again the date which was earlier fetched by 1st query remains there.

For refreshing the data i hav used following code snippet :-

SUBMIT BUTTON OF INPUT SCREEN

public

void onActionSubmit(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )

{

//@@begin onActionSubmit(ServerEvent)

Zimportorderspnr zimp =

new Zimportorderspnr();

Zmf002_Select_Orders_Pnr_Input zinp =

new Zmf002_Select_Orders_Pnr_Input();

IPrivateAuctionServiceFeesInDateRange.IEndElement endnode = wdContext.currentEndElement();

Date enddate = endnode.getDate();

IPrivateAuctionServiceFeesInDateRange.IStartElement startnode = wdContext.currentStartElement();

Date startdate = startnode.getDate();

IWDMessageManager msg = wdComponentAPI.getMessageManager();

if (startdate == null) {

// *************************** FOR DISPLAYING MESSAGE

msg.reportMessage(IMessagePanel.MISSING__INPUT,

null, false);

}

else {

if (enddate == null) {

enddate = startdate;

}

if (enddate.before(startdate)) {

msg.reportMessage(IMessagePanel.END__DATE,

null, false);

}

else {

zimp.setFrom_Date(startdate);

zimp.setTo_Date(enddate);

zimp.setFlag(

"D");

zimp.setVendor(wdContext.nodeIndustrykey().currentIndustrykeyElement().getLifnr());

wdContext.nodeImportorderspnr().bind(zimp);

zinp.setImportorderspnr(zimp);

wdContext.nodeZmf002_Select_Orders_Pnr_Input().bind(zinp);

wdThis.wdGetSelectOrdersPnrCustController().executeZmf002_Select_Orders_Pnr_Input();

wdThis.wdFirePlugToCumulativeService();

}

}

BACK BUTTON ON OUTPUT SCREEN

public void onActionBack(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )

{

//@@begin onActionBack(ServerEvent)

wdContext.invalidate();

wdContext.clearSelection();

wdThis.wdFirePlugToAuctionServiceFeesInDateRange();

//@@end

}