Copy link to clipboard
Copied
Hi
How can i create list at form like this
Not necessarily multiple list but i need view few options on screen
Thanks
That's a problem in Windows 10 with (I think) CS6. The fix is simple: instead of adding the listbox to the window, add a dummy group to the window and add the listbox to that dummy. Change the first three lines as follows:
var w = new Window ("dialog");
var dummy = w.add ("group")
var myList = dummy.add ("listbox", undefined, ["one", "two", "three"], {multiselect: true});
Note that you should set the multiselect property.
P.
Copy link to clipboard
Copied
Hi,
Try this..
var w = new Window ("dialog");
var myList = w.add ("listbox", undefined, ["one", "two", "three"]);
var print = w.add ("button", undefined, "Print");
print.onClick = function ()
{
for (var i = 0; i < myList.items.length; i++)
$.writeln (myList.items.text);
}
w.show ();
Thanks
Copy link to clipboard
Copied
I don't know why but i see empty list
Copy link to clipboard
Copied
That's a problem in Windows 10 with (I think) CS6. The fix is simple: instead of adding the listbox to the window, add a dummy group to the window and add the listbox to that dummy. Change the first three lines as follows:
var w = new Window ("dialog");
var dummy = w.add ("group")
var myList = dummy.add ("listbox", undefined, ["one", "two", "three"], {multiselect: true});
Note that you should set the multiselect property.
P.
Copy link to clipboard
Copied
Thank you very much
You are the best