FORM INHERITANCE

Currently working on using Form Inheritance to reduce code complexity in existing application for our Sailing Magazine as a part of eliminating DEPRECATED METHODS, in this case in regards to the use of //application.showFormInDialog(forms.frm_web_resources,-1,-1,-1,-1,‘Resource on Web’,false,false,‘’,false )

I created a new form: baseModalDialog.frm and created a creation method:

/**

  • public
  • @param {JSRecord | JSFoundSet} requestedFoundset
  • @param {String} windowTitle
  • @properties={typeid:24,uuid:“EDAE4C99-CF9A-481E-9F98-3E2E24016683”}
    */
    function openModal(requestedFoundset, windowTitle ) {
    // ABSTRACT FORM

if(requestedFoundset) {

foundset: requestedFoundset ;
}
// OPEN MODAL

var win = application.createWindow( controller.getName(), JSWindow.MODAL_DIALOG);
win.title = windowTitle;

win.show(this);

// Note: Execution halts here until after return from modal dialog

win.hide();

}

Then set forms.frm_web_resources to be extended from the new form. This all seems to look good.
But when I create a reference this from another form. The method openModal() does not CODE COMPLETE.

I can only get it to CODE COMPLETE, by creating a method in the CHILD FORM and calling _super.openModal( foundset, windowTItle) from it. That seems to make inheritance useless.

Any ideas - perhaps I have not done something that is required to make this work properly.

Daryl()

Now that is ODD, not sure what changed, but it started working when I added another FORM and set its inheritance to baseModalDialog …