Information générale
Catégorie:
Gestionnaire d'écran & Écrans
Hi Timothy.
>> Sounds like alot of code there. I was fooling around and accomplished by putting this into the gotfocus event of the combobox1:
[thisform.myCombobox1.RowSourceType = 3
thisform.myCombobox1.RowSource = "SELECT name,noun from bsyear00 WHERE subs(bsyear00.noun,2,3) $ thisform.mytextbox2.value INTO cursor cur1"]
and it worked. <<
< lol > It really is not that much code ;-). All the code in the Init of the form does is programatically set up the RowSources for the Combo and the list boxes. The reason for this is that you cannot use 'Thisform' in the property sheet to set them up. The code is in the init of the form because that is the only place where you can be sure that both controls are already instantiated. If you put the code to set their respective RowSources in the individual controls' inits, you could not be sure that the dependent control would instantiate after the control that it depends upon.
All that remains to to issue a requery of the dependent control in the GotFocus of the controling one.
Marcia
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement