on 05-24-2009 8:55 AM
Hi Experts,
I refered the following thread and done the below steps
1.Create a Button called Exit.
2.Create an action for this button.
3. In the event handler for this button, write the following code:
String Url;
try {
Url = WDURLGenerator.getWebResourceURL(wdComponentAPI.getComponent().getDeployableObjectPart(),"close.html");
wdThis.wdGetAtpEmpDetailsWinInterfaceViewController().wdFirePlugExitPlug(Url);
} catch (Exception e) {
wdComponentAPI.getMessageManager().reportException("Technical Exception occured in the application : " + e.toString(), true);
}
4.Create a html page called u201Cclose.htmlu201D with Javascript code for closing a browser window.
5.Place this html page in SRC -> Mimes -> Components -> Project Structure(Create this folder and place the html page in this folder)
I have used Ie 7.0
My questin is when i clicking the button. It show popup message like
"Do you want to close this window " I don't want this popup.
without popup i need to close this window? How to do that?
Regards,
Manivannan P
Hi Manivannan p,
1.Create a Button called Close.
2.Create an action for this button.
3. In the event handler for this button, write the following code
You can try this
public void onActionClose(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
{
//@@begin onActionClose(ServerEvent)
WDPortalEventing.fire("urn:com.sapportals:navigation", "CloseWindow", "");
//@@end
}
This will help you closing the window with out Popup
Here we are calling a "Portal Event" called " CloseWindow" to close the windoe
Get back if you have any questions
Thanks & Regards
Swetha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Manivannan P,
1) Does the code which i have attached before is asking some imports if so... have you imported these two API's
import com.sap.tc.webdynpro.clientserver.event.api.WDPortalEventMode;
import com.sap.tc.webdynpro.clientserver.event.api.WDPortalEventing;
2) This page which you are trying to close might be a part of an Application....could you please try to integrate this page in the main application, and then try clicking on the button
Thanks & Regards
Swetha
Hello ,
Please use following procedure.
1.Create an extra view called "CloseView".
2.embeed an IFRAME UI Element in that view and specify the source property of IFRAME to close.htlm(html page saved in mimes)
2.maintain navagation between your mainView and closeview
3.On click of close button,fire outbound plug from MainView which navigates to closeview.
hope this helps.
Thanks,
Balaram Naidu Bankuru
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
88 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.