Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Combo Box
Message
From
14/10/2001 06:31:12
 
 
To
14/10/2001 06:00:43
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Title:
Miscellaneous
Thread ID:
00568259
Message ID:
00568266
Views:
24
>I have a table index on "Clients.Name" and I have a combo Box to select Clients, I want the table be displayed in Alfabethic order in the combo Box. How to do that?

Carlos Lima, your name seems to be Portuguese, and Mindelo is a locality near my home place (Porto - Portugal) but the flag...

Anyway, about the question you have:

The more practical way to do that is the following:

* On the form load method create the SQL statement that follows
SELECT a.name, a.clientno FROM clients a ORDER BY a.name INTO CURSOR cursor_name

* Define the following combo properties
combo1.controlsource = 'orders.clientno' && Assuming that you have a table
&& named orders and the field you want
&& to define is one called clientno
&& but it could be a memory variable
&& or a form user defined property
combo1.rowsourcetype = 2 && 2 = table or cursor alias
combo1.rowsource = 'cursor_name'
combo1.style = 2 && dropdown list
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform