Combo Box << Get Items bug, need work around<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />I just discovered an inconvenient bug:
Names Default to here(1);
list = {};
for(i=1, i<=10000, i++,
insert into(list, char(i))
);
New Window("test", cb = combobox(list));
cbitems = cb << Get Items;
nitems(cbitems);
//1000
Yes that's right, Get Items is only returning the first 1000 options in the combo box. (I'm running JMP 12 Pro on Windows 7)
Is there a way to iterate through all the items in a combo box?
Re: Combo Box << Get Items bug, need work aroundThe problem with a list box over combo box isn't necessarily aesthetic as much as it is real estate. Also, I am using search functions, which is the reason why this all came about.
Re: Combo Box << Get Items bug, need work aroundHere's another idea to consider. I often have long lists of things which are displayed using a listbox. The user can either select directly from the listbox, or I include a search box which trims down the listbox of items to those that contain the search string. I can post some sample code if you like.
Re: Combo Box << Get Items bug, need work aroundThis is a really smooth work around! Thanks for the suggestion.
Just added a lb << Clear Selection; lb << set selected( cb << get ).
Re: Combo Box << Get Items bug, need work aroundWhat about a hidden ListBox that mirrors the ComboBox?
Names Default to here(1);
list = Repeat( i = 0; {i++; Char( i )}, 1e4 );
NewWindow( "test",
lb = ListBox( list, <<visibility( collapse ) ),
cb = ComboBox( lb << get items, lb << set selected( cb << get ) )
);
Re: Combo Box << Get Items bug, need work aroundI guess this is possible if you include a radio box to determine which combo box has the selection. It's definitely going to look messy though.
Re: Combo Box << Get Items bug, need work aroundperhaps the most low tech solution is having a few combo boxes to allow braking the lists into sub lists of a thousand each. this would only be worth if there are not many thousands of items. it may also make it easier for the user to select a value out of such long lists.
Re: Combo Box << Get Items bug, need work aroundI submitted the case when I wrote this post. I'm also guessing from your hyphenation of bug that you mean to suggest that this is a feature?
Anyways, any good way to iterate through a Combo Box? I couldn't find one.
Another option I figured is to throw the list into a private data table column and track that over the combo box, but I'd prefer not making the system more complex.
Another option still is to use a list box instead of combo box, but that's going to make the GUI too large/ugly.
Re: Combo Box << Get Items bug, need work aroundI can not see a workaround for your issue.
i tried adding different elements to the msg, which resulted in no change in the results.
I suggest you submit the "bug" to support@jmp.com so it becomes an offically tracked item.
Re: Combo Box << Get Items bug, need work aroundThank you for reporting this issue to the JMP Support team. I'm happy to report to anyone finding this post that the issue was fixed in JMP 13 and later.