Here is a sample to see if it would work with app.doScript: var w = new Window ('dialog {text: "Script List", properties: {closeButton: false}}'); var Pan1 = w.add ('panel {alignChildren: "left"}'); mL = Pan1.add("listbox", ["0", "0", "600", "600"]); with (mL) { for (var i = 0; i < 1; i++) var listItem1 = mL.add ("item", "Text Auto FIT" ) // Run this script and the one below. etc... var listItem2 = mL.add ("item", "Crop Marks"); mL.revealItem (mL.items.length - i/1); } mL.onClick = function() { var curSelection = this.selection.index; //alert ( "You clicked item: " + this.selection.index ); switch (curSelection) { case 0: app.doScript(script1); break; case 1: app.doScript(script2); break; } } w.show (); function script1() { alert ("run Text Auto FIT.jsx"); } function script2() { alert ("run Crop Marks.jsx"); }
... View more