on 10-17-2006 11:02 AM
Hi,
I'm looking for a solution which show me up a pop-up dialog box, and after the creation of this, it will block the execution of my main code until the user click on the OK button into the popup dialog box.
I try to use modal window, but it doesn't block the execution.
e.g.
CODE A
CREATION DIALOG BOX
SHOW DIALOG BOX
CODE B
when the dialog is shown, then the code B is executed only if we destroy the dialog box.
Thanks
Regards,
hi
good
go through these links, which ll give you brief idea about the dialog box and the execution procedure.
https://weblogs.sdn.sap.com/pub/wlg/4513?page=last&x-showcontent=off [original link is broken] [original link is broken] [original link is broken] [original link is broken]
thanks
mrutyun^
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Berthe,
If you are using WD for Java then:
1. Use IWDWindowManager (wdComponentAPI.getWindowManager()) to create confirmation dialog.
2. In some action handler run code A, then open confirmation dialog
3. In event handler for button in confirmation dialog place code B.
Valery Silaev
SaM Solutions
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Berthe,
Unfortunately, there are no simplier solution with WD. In some other Java web frameworks like Cocoon (with Javaflow support, Java) or RIFE (Java) or Seaside (Smalltak) you may use continuations. So you can write liniear code in for:
List modifiedRecords = getModifiedRecords();
boolean confirmUpdate = queryUserAndWait("Modify records?", modifiedRecords);
if (confirmUpdate)
updateRecords(modifiedRecords);
In aforementioned frameworks thread state is serialized and response is sent back to user when queryUserAndWait method invoked. After user submits answer, frameworks restore erxecution state of thread and resume (continue, hence continuations) execution right after queryUserAndWait method return.
Again, in WD you have to emulate this behavior with separate action/event handlers.
Valery Silaev
SaM Solutions
Hi,
Sorry but I don't understand your solution :(. It sounds good, but I don't get it.
Otherwise, I don't understand an other thing. I've made this code but it desn't work at all:
IWDWindowInfo windowInfo = (IWDWindowInfo) wdComponentAPI.getComponentInfo().findInWindows("ScheduleLinesChoiceBox");
IWDWindow window = wdComponentAPI.getWindowManager().createWindow(windowInfo, true);
window.setWindowPosition(WDWindowPos.CENTER);
window.setTitle("ATP Control");
window.open();
wdContext.currentContextElement().setScheduleLinesPossibleWindow(window);
wdContext.currentContextElement().setWait(true);
while(wdContext.currentContextElement().getWait());
With your framework, how can I implement it with this requirement ?
Regards,
User | Count |
---|---|
82 | |
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.