Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Allow multiple item selection in combobox?
Message
From
07/12/2000 05:23:01
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00450016
Message ID:
00450276
Views:
34
Hi!

In addition to Nadya answer:

Anyway, to organize that you will need to make some programming, because no generic way to organize that just using properties of controls.

Its very depended on what you goind to do with such combobox.

If you just need to select some items frm list, the best way is mover box (2 listboxes, left contains all items, right - selected items; and 4 buttond - add item, add all, remove all and remove item)

If you just need to select a list of values and store them in the data field, nice way is to use listbox with multi-select. When form loads, selected items shown automatically, and user can select/remove item from list. However, with the same success you can use grid or tree-view control with checkboxes.

If you need exactly combobox with multi-select functionality, use listbox as drop-down part of combobox, exactly as Nadya mentioned. In the DropDown event of combobox create listbox in run-time, fill it by values, show just under combobox and use NODEFAULT to do not show combobox's native list. Than, when ListBox loses focus (LostFocus event), hide that listbox and save values selected in listbox.

>>Is it possible to allow a user to choose multiple items from a drop-down list in a combobox? If yes, what properties allow this to happen? If yes, would the items all be stored in one field or multiple fields? Or would I need to use a listbox instead? Please clarify these capabilities for me. Thanks.
>>
>>I have never tried this before. I don't even know if it's possible, but I assume it is.
>
> Steve,
>
> You can use listbox for that. It has a property (MultiSelect ?) to allow this functionality. Note, that multiselect listboxes work properly only for number of items less than 100. If you want more items to be displayed, as one of the alternatives, you can use Cetin's Basoz MultiSelect grid, available for download in Files section. You can also take a look at my container class, which is based on this multiselect grid.
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.com
ICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs

It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.
Previous
Reply
Map
View

Click here to load this message in the networking platform