on 03-26-2010 11:42 AM
Hi gyus, another challenge for community!
I've a button to do some actions but I want to show a confirmation popup before. If user clicks button Yes the execution should go on, but if user clicks No the execution should be interrupted.
An example:
ONACTIONSAVE
Throw popup
If YES
save_data()
else.
stop.
endif.
Thanks
Edited by: vanbelal on Mar 26, 2010 12:42 PM
Edited by: vanbelal on Mar 26, 2010 12:43 PM
Hi,
here is your clue:
a) create a popup in your action method onactionsave by using method of if_wd_window_manager "create_popup_to_confirm"
of type OK, CANCEL.
b) then create event handlers for OK, Cancel by using method of subscribe_to_button_event of interface if_Wd_window, you will get window referecne as returning param as a result of the pop up created in first step.
Write only this much of code in this method.
Now in the event handler method if OK write all you code for save.
for cancel dont write any code.
This is it.
Hope this helps
Regards
Manas Dua
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi again,
I want to show a window with an input field and a button to save the value on a variable.
The problem is I can't interrup general flow execution until user press the button 'Ok' for example.
I can't do that with CREATE_POPUP_TO_CONFIRM method, and if I use CREATE_WINDOW the execution doesn't stop.
An example step by step that I want to do:
1) User press button 'Reject'
2) Throw confirm popup Yes, No (on YES event I have implemented source code to do the changes)
3) If Yes => I have to show another kind of popup asking for a value 'Reason for rejection' input field and 'Save' button or similar.
4) Continue flow of 'Reject' button
Thank you guys!
Reopened question for new requirements.
Thank you
Edited by: vanbelal on Apr 6, 2010 11:04 AM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
In my opinion, throwing a pop up after pop up is not a good UI design.
Can't you try create your own custom window with input field and OK, CANCEL button inside the view and then launch this view from your original view.
So your window could be like this:
Are you sure you want to Reject?
If Yes, then please enter the reason for rejection: _________________
OK, CANCEL
In your pop up view you can define events for OK, CANCEL and code your functionality there.
Regards
Manas Dua
User | Count |
---|---|
81 | |
10 | |
10 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.