var ctx = document.thisItem;
var q = ctx.newItem("Form", "get");
q.setAttribute("select", "id,width,height");
q.setProperty("name", "DEF"); //your form name goes here
var r = q.apply();
var height = r.getProperty("height", "500");
var width = r.getProperty("width", "500");
var param = new Object();
param.title = "Title of dialog box goes here";
param.formId = r.getItemByIndex(0).getID(); // the id of the Form to be used
param.item = ctx;
param.aras = top.aras; // the aras object
param.isEditMode=true;
var res = showModalDialog(
"ShowFormAsADialog.html",
param,
"dialogHeight:" + height + "px; dialogWidth:" + width +
"px; " +
"status:0; help:0; resizable:1; scroll:0;"
);
Put the above code into a method that you call from the onClick of the button.
This should show the dialog box DEF.
Hope this helps.
Brian.Copyright © 2025 Aras. All rights reserved.