these combo boxes again...

lynsey2

Registered User.
Local time
Today, 10:01
Joined
Jun 18, 2002
Messages
439
I have already posted about my combo boxes but cant find it..this is another question but i feel bad about starting a new thread...
anyway

i have 4 combo boxes
Drug Form Frequency Strength

when i pick the drug, i want only the forms that the drug comes in to be shown in the Form combo box, on picking the form from this list i want the Frequency that the selected drug in the selected form comes in, on picking the frequency i want the Strength for the selected drug in the selected form with the selected frequency to be in the Strength combo box.

what i have done:
created a query that links the tables i have and shows a list of all the combinations that the drug, form, frequency and strength come in

created 4 combo boxes with the above titles

went into the Row Sorce of DRUG and tools>>view totals(to get the drug name only once)(its a seql qry)

went into the Row sorce of the Form combo and set the qry to have the drug and the form shown with [Forms]![ARTScript]![pickDrug] as the criteria for the drug column

went into the row sorce of the Frequency combo and set it so you see Drug, form, frequency i have set the criteria for the drug and the form the same as above

in all of the above combos i have gone into the onGotFocus event and put code e.g for the Form combo
Me.pickForm.Requery

my combo boxes work for picking the drug, form and frequency but they do not work for picking strength and i have no idea why

so in effect thats what i need to find out so if you guy's have any clues i would be verry happy to hear them and give them a shot!
 
Lyns - have just looked at the db you sent me yesterday as I remembered the form that you are now talking about.

Don't quite know how to put this, but I think you might find that it's a small spelling error that's your problem. You've got an extra "e" in frequency. ;) I just tried it and it worked.

Forms![ARTScript]![pickFrequency2]

I checked all lines and they're different (1, 2, 3/4). You need to look at the second line, change the spelling then use the same principle in each line.
 
Last edited:
:o :o thank you for replying honey i was just coming to let you all know that i have fixed it and yes you were correct i did spell it wrong!:o :o
its working now properly :o
 

Users who are viewing this thread

Back
Top Bottom