Form and combo box

Yoshi88

New member
Local time
Today, 21:08
Joined
Mar 14, 2001
Messages
9
Someone gave this code to speed up my form. It is suppose to load the list of the combo box only when required

Dim strSQL as String
strSQL = "SELECT DISTINCT [TableName].[FieldName] FROM [TableName] ORDER BY [TableName].[FieldName];"
Me.cboComboBoxName.RowSource = strSQL

It doesn't work and the debugger insist on the last line Me.cbo...

Can someone help me
 
If you are trying to use the code exactly as it is here then you need to make some changes. Where the code says TableName put in the name of your Table that you want to get the information from. Where it says FieldName put in the name of the field in your Table that you want displayed in the Combo box. And where it say cboComboBoxName put in the name of your Combo box....
 

Users who are viewing this thread

Back
Top Bottom