on 01-11-2011 6:52 AM
hi, dear all:
Now, i have encountered one tough issue:
In my WD, i have one button named "Refresh" in the main view
Now, i want the WD application will execute again( that means just like when we execute the application first time when we test the WD application) when the user presses the button "Refresh"..
The requirement is:
We want the Window doesnot close(and open again)..the better is : user can not know that he execute the WD once more...
I have tried some ways, but it doesnot work very fine.
Now, can any friend give me some advice on this issue?
Thanks very much.
wht u can do is...put the entire code in modify view....and u dont need to put any code in button action
bcoz whnever a button(in ur case refresh) will b clicked.....an event wil b generated...bocz of which modify view wil b again executed....and hence the data wil be refreshed....
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
We will find the way.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Edison,
You can code for opening web-link on pressing of your Button 'REFRESH'. While calling web-link, you can pass 'Application-URL' and set the Browser-Window' to be same. This way you can achieve your requirements.
Add a linktourl UI in your view.
and in the reference properly give YOUR_APPLICATION_URL
[http://help.sap.com/saphelp_nw70ehp1/helpdata/EN/25/e2f0416ab6da6fe10000000a1550b0/content.htm]
For using same window, you can set TARGET.
This way that same application would get opened up with all its nodes refreshed.
Hope this would be of some help.
Thanks.
Kumar Saurav.
Edited by: Kumar Saurav on Jan 11, 2011 8:21 AM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
thanks the upper 2 experts.
However, just like what i said before:
i don't want the main window of this WD application to be closed..
we don't want to put all coding( WddoInit in Component contorller, plug-hanlder of main window..) in the WdDoModifyView...
And we provide one button "Refresh", we don't want to execute the F5..
Thanks again..
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I dont understand what is the problem in using an exit plug and firing it in the event handler of the button refersh.
give it the url of same application and fire it.
it will open in the same window just like you have run the application again.
please revert back if you want furthere assistance in firing the exit plug
thanks
sarbjeet singh
use exit plug and in the url parameter give the parameter for the same application
have you tried this?
thanks
sarbjeet
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi,
using the refresh of Internet explorer or pressing F5 also will execute the application again...but you may also try the below mentioned code on the action of the refresh button....but i suggest that using refresh of Internet explorer will be better option.
method refresh .
DATA LO_WINDOW_MANAGER TYPE REF TO IF_WD_WINDOW_MANAGER.
DATA LO_API_COMPONENT TYPE REF TO IF_WD_COMPONENT.
DATA LO_WINDOW TYPE REF TO IF_WD_WINDOW.LO_API_COMPONENT = WD_COMP_CONTROLLER->WD_GET_API( ).
LO_WINDOW_MANAGER = LO_API_COMPONENT->GET_WINDOW_MANAGER( ).
CALL METHOD LO_WINDOW_MANAGER->CREATE_EXTERNAL_WINDOW
EXPORTING
URL = 'url of the application'
MODAL = ABAP_FALSE
HAS_MENUBAR = ABAP_TRUE
IS_RESIZABLE = ABAP_TRUE
HAS_SCROLLBARS = ABAP_TRUE
HAS_STATUSBAR = ABAP_TRUE
HAS_TOOLBAR = ABAP_TRUE
HAS_LOCATION = ABAP_TRUE
RECEIVING
WINDOW = LO_WINDOW.LO_WINDOW->OPEN( ).
IF SY-SUBRC EQ 0.
ENDIF.
endmethod.
thanks and regards,
sahai.s
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
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.