Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
More combo box probs---
Message
De
06/08/1998 11:24:26
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de projet
Divers
Thread ID:
00124475
Message ID:
00124487
Vues:
15
>Cetin,
>
>Here's the code from the cboDept.click():
>
>LOCAL ARRAY lacGroupArray[1]
>LOCAL lnACnt && set local variable for array counter.
>
>store '' to lacGroupArray
>lnACnt = 1 && initialize variable
>
>gcDeptNo = THISFORM.cboDept.VALUE
>
>IF !EMPTY(THISFORM.cboDept.VALUE)
>*--Redefine group array pertaining to the department chosen
> SELECT DISTINCT snag_temp.ass_l_grp ;
> FROM snag_temp ;
> WHERE snag_temp.ass_l_dept = gcDeptNo ;
> INTO ARRAY lacGroupArray
> THISFORM.cboGroup.CLEAR &&Clear combo box
>FOR lnACnt = 1 TO ALEN(lacGroupArray)
> THISFORM.cboGroup.ADDITEM (lacGroupArray[lnACnt])
> lnACnt = lnACnt + 1
> ENDFOR
> THISFORM.cboGroup.ENABLED = .T. &&Enable combo box
> release lacGroupArray &&release array from memory
>ELSE
>THISFORM.cboGroup.ENABLED = .F.
>ENDIF
>
>The funny thing is that it worked this morning when I tried it, now...no dice
>
>Thanx
>Perry
Perry,
I'm revising your code just now but are you sure this code worked as intended. There is an extra skip in for lnACnt...endfor (endfor does an implicit increment). What are rowsource* props ?
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform