list box widget not working as expected.Here is a simple snippet which pops up a list box and when an item is selected it should simply return the item to the log window. In reality I have a function which will do something with the returned item.
However, in JMP 15 it always return the item twice which is odd behavior. Maybe this is an unintended use case and I need to use this widget another way.
myListBox = listBox({"A", "B", "C"}, width(50), maxSelected(1), nlines(3),
<< script(
mySelection = myListBox << getSelected;
print("I selected: " || mySelection[1]);
);
);
newWindow("Test", myListBox);
ScriptingRe: list box widget not working as expected.I am running JMP 15.2.1 and I get only one printing to the log
myListBox = listBox({"A", "B", "C"}, width(50), maxSelected(1), nlines(3),
<< script(
mySelection = myListBox << getSelected;
print("I selected: " || mySelection[1]);
);
);
newWindow("Test", myListBox);
/*:
DisplayBox[EvalContextBox]
"I selected: B"Re: list box widget not working as expected.Thanks Jim. Interestingly it does not happen on JMP 12. I also tried it on another machine with a separate JMP install (Also JMP 15.0.0) and it does this double print.
The issue though is that it seems to run EVERYTHING which is part of a <&amp;amp;lt;P&amp;amp;gt;&amp;amp;nbsp;&amp;amp;lt;/P&amp;amp;gt;&amp;amp;lt;P&amp;amp;gt;I&amp;amp;amp;#39;ll see if I can update my JMP to &amp;amp;gt; 15.0.0&amp;amp;lt;/P&amp;amp;gt;&amp;amp;lt;/lingo-body&amp;amp;gt;