I have a modal window and I need to preset some values in a combobox. I can do this in a non-modal window but not in the modal window. Anyone know how?
Here's an example from the JSL manual. This is a non-modal window, so the item "Two" is preselected in the combobox.
New Window( "Example",
cb = Combo Box(
{"One", "Two", "Three"},
selection = cb << GetSelected();
Print( "Selected: " || selection );
)
);
cb << Set( 2 );
If I change it to a modal window I can't preset "Two" for the combobox:
New Window( "Modal Example", << modal,
cb = Combo Box(
{"One", "Two", "Three"},
selection = cb << GetSelected();
Print( "Selected: " || selection );
)
);
cb << Set( 2 );