This forum is closed to new posts and
responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:
as the script. When I changed it to remove the return, the dialog was no longer "modal", in that it would not wait for user input. It presented, stayed about a second, then auto-dismissed. If I'm real quick I can type something and click a button, but no matter what I do, the result is the same.
- The custom control containing the dialog looks like this:
I added the dialog_create() at the bottom because you have it. If I put dojo.addOnLoad(dialog_create()) in the script block I get an error, but this straight dialog_create() seems to work. After putting that in, it did start running the CSJS (as indicated by the alert popping), and it does trigger some server-side activity, but only an afterRestoreView. It will not actually save, or run any save events on the data source.
I have tried every variation of immediate, save, and submit. The most I can get it to do is run afterRestoreView.
- I do not have a data source associated with any dialog. There is only the data source on the XPage that the dialogs are on, which is named "Ticket".
- Here's dialog_create() and show_me(), in an included client-side library:
function dialog_create(id, title1) {
var dialogWidget=dijit.byId(id);
if(dialogWidget && dialogWidget.destroyRecursive) dialogWidget.destroyRecursive(false);
dialogWidget=new dijit.Dialog(
{title: title1},
dojo.byId(id)
);
var dialog=dojo.byId(id);
dialog.parentNode.removeChild(dialog);
var form=document.forms[0];
form.appendChild(dialog);
dialogWidget.startup();
return dialogWidget;
}
/* Display a dijit dialog based on a Custom Control, creating it if necessary
Based on a R8.5 Notes.net forum post by Lothar Mueller, and dijit web research
*/
function showMe(dlgName, dlgTitle) {
var dlg=dijit.byId(dlgName);
if(dlg) dlg.show();
else {
dlg=dialog_create(dlgName, dlgTitle);
if(dlg) dlg.show();
else {
alert(dlgName+" explicit create failed");
return false;
}
}
return true;
}
Previously I had this code at the bottom starting from the line "var dialog=..."
- If I put the showMe() call back, it's being typcially flakey. Before I replaced "return showMe(...)" with "dijit.byId(...).show()", it would wait for user input. Now that I've put "return showMe()" back, it will no longer wiat for input. No matter what I do, it pops the dijit dialog and immediately dismisses it. Period. The only line I changed is the button to invoke the dialog, yet it's behaving differently. This is the story of my entire XPages experience. Disastrous inconsistency.
- The dialogs are all what should be painfully trivial things, like requesting some input and saving the document. In R-prior this would have taken minutes to build a Form, present it in a pop-up, and do a document.sumbit() to trigger WebQuerySave. Minutes.
I'd appreciate any input at all. Meantime I'm going to try the hokey pop-up window method. I've squandered so much time on what should be a cake walk that it's not even remotely funny...
Feedback response number DGIE86WMTF created by ~Holly Zekhipisonnivu on 06/30/2010