I
IT_roofer
Here's my scenario:
Userform1 Contains two (2) Labels (Label1 and Label2) and three (3)
ComboBoxes (ComboBox1, ComboBox2 and ComboBox3):
(System Type) Label1.Caption = Asphalt
(Vendor) Label2.Caption = JonCo
(Base Layer) ComboBox1
(Mid Layer) ComboBox2
(Top Layer) ComboBox 3
When the Userform_Initialize() routine runs, I would like it to check the
Caption of Label2 for the vendor name (in this case JonCo) and then populate
the list of ComboBox1, ComboBox2 and ComboBox3 with the correct items from
the database; in this case jonco.mdb. IE: if Label2.Caption = AllanCo then
myDb = OpenDatabase("allanco.mdb")
jonco.mdb info:
Only three (3) columns: prType, prUse and prName
I don't know how to write the sql query string, but I've seen enough info
by searching I can establish the database and the connection. I just need to
load the data now... so here's what I need from the database:
If the prType = hot and prUse = base then I need ComboBox1 to be populated
with all matching entries from the prName column. If prType = hot and prUse =
mid then populate the list of ComboBox2 and same thing for ComboBox3: if
prType = hot and prUse = top then fill in ComboBox3 with all matching
entries... It sounds easy to me, but I lack the Access experience to
correctly construct the query string.
Thanks in advance!!
Userform1 Contains two (2) Labels (Label1 and Label2) and three (3)
ComboBoxes (ComboBox1, ComboBox2 and ComboBox3):
(System Type) Label1.Caption = Asphalt
(Vendor) Label2.Caption = JonCo
(Base Layer) ComboBox1
(Mid Layer) ComboBox2
(Top Layer) ComboBox 3
When the Userform_Initialize() routine runs, I would like it to check the
Caption of Label2 for the vendor name (in this case JonCo) and then populate
the list of ComboBox1, ComboBox2 and ComboBox3 with the correct items from
the database; in this case jonco.mdb. IE: if Label2.Caption = AllanCo then
myDb = OpenDatabase("allanco.mdb")
jonco.mdb info:
Only three (3) columns: prType, prUse and prName
I don't know how to write the sql query string, but I've seen enough info
by searching I can establish the database and the connection. I just need to
load the data now... so here's what I need from the database:
If the prType = hot and prUse = base then I need ComboBox1 to be populated
with all matching entries from the prName column. If prType = hot and prUse =
mid then populate the list of ComboBox2 and same thing for ComboBox3: if
prType = hot and prUse = top then fill in ComboBox3 with all matching
entries... It sounds easy to me, but I lack the Access experience to
correctly construct the query string.
Thanks in advance!!