Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to show value not in rowsource of the combobox
Message
From
16/02/2003 09:14:24
 
 
To
15/02/2003 23:35:20
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00753822
Message ID:
00753860
Views:
41
Hi Alex.

A combobox has a two column rowsource with column two bound to control source. Since I am using synthetic test data, some illegal values got into controlsource. The illegal value does not show in the combobox yet stays in the table. Better behavior would be to show current illegal value. How would you accomplish that?

C'mon! I know that you have KiloFox < s >. Take a look at Chapter 5:

So what if I want to bind my combo to a value that isn't in the list? (Example: CH05.VCX::cboSpecial and CH05.VCX::cboNotInList)

The first question that leaps to mind here is "Then why are you using a combo box?" Combo and list boxes are used to limit data entry to a set of predefined selections. Permitting the user to enter an item that isn't in the list defeats the purpose of using a combo box in the first place. Having said that, we realize there may be occasions where this sort of functionality is required. For example, let's suppose a particular field in a table is usually populated from a set of standard selections. However, occasionally none of the standard selections are suitable and the end user needs to enter something that is not in the list. Clearly, if the non-standard items were regularly added to the underlying lookup table, the table would grow quickly with seldom used entries. In this instance, the field binding to the combo box must contain the description of the item in the lookup table and not its key value. Obviously, if we allow the field to be bound to items that are not in the list, we must store the information in this non-normalized manner. The only place to "look up" such ad hoc items is in the bound field itself!
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform