Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Display all groups in Combobox
Message
 
To
21/10/2006 01:17:59
Aaron K. Y. Chu
Health & Care Co. Ltd.
Hong Kong, Hong Kong
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
01163776
Message ID:
01163782
Views:
9
This message has been marked as the solution to the initial question of the thread.
>Dear All,
>
>I used to use a combobox to filter the data to be displayed...like so
>
>.combobox1.rowsource = "select group_name from tableA into cursor tmp_group"
>
>
>However, the user cannot select all groups... my plan is to add a select item into combobox e.g. "Show all groups"... is it possible?
lcShowAll = PADR("Show all groups", LEN(tableA.group_name))
TEXT TO .combobox1.rowsource NOSHOW PRETEXT 15 TEXTMERGE
     select group_name
            from tableA
     UNION
     SELECT  '<<lcShowAll>>' AS group_name
            from tableA
     into cursor tmp_group"
ENDTEXT
or:
.combobox1.rowsource = "select group_name from tableA into cursor tmp_group READWRITE"
.combobox1.requery()
INSERT INTO tmp_group VALUES([Show all groups])
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Reply
Map
View

Click here to load this message in the networking platform