What's wrong with this dialog box? I can't get the value.
Prompt: getCn ,GetCsp is undefined
The dialog box has been bothering me.
Can this mm be entered like this? How can I make the value in this dialog box be mm?
Thank you very much.
var getCn, getCsp;
makeDialog();
alert("columns:" + getCn)
alert("spacing:" + getCsp)
function makeDialog() {
var theDialog = app.dialogs.add({ name: "Column number and spacing settings", canCancel: true, minHeight: 600, minWidth: 400, });
with (theDialog.dialogColumns.add()) {
staticTexts.add({ staticLabel: "number of columns:" });
staticTexts.add({ staticLabel: "spacing:" });
}
with (theDialog.dialogColumns.add()) {
var getCn = textEditboxes.add({ editContents: "4" });
var getCsp = textEditboxes.add({ editContents: "6mm" });
}
if (theDialog.show() == true) {
//dialog results preset and page range
getCn = getCn.editContents.split(',');
getCsp = getCsp.editContents.split(',');
theDialog.destroy();
}
}


