T
taxidermist
I have a textbox on a form that user will enter a string into and
press a button. An example of what they will enter is "BD532313CW".
Once they press the button i take the first three numbers (532 in this
case) and assign them to a string variable named myString.
Next I have 2 combo boxes on a form named cmbAcct and cmbDisp. I have
a table named "Swbs" that has three fields in it Swbs.Acct, Swbs.Disp,
and Swbs.Num. There are duplicates in all fields. I need to populate
cmbDisp with the distinct data in Swbs.Disp where Swbs.Num =
myString. Likewise I need to populate cmbAcct with distinct data from
Swbs.Acct where Swbs.Num = myString.
How can I do this with VBA code?
press a button. An example of what they will enter is "BD532313CW".
Once they press the button i take the first three numbers (532 in this
case) and assign them to a string variable named myString.
Next I have 2 combo boxes on a form named cmbAcct and cmbDisp. I have
a table named "Swbs" that has three fields in it Swbs.Acct, Swbs.Disp,
and Swbs.Num. There are duplicates in all fields. I need to populate
cmbDisp with the distinct data in Swbs.Disp where Swbs.Num =
myString. Likewise I need to populate cmbAcct with distinct data from
Swbs.Acct where Swbs.Num = myString.
How can I do this with VBA code?