Fill ComboBox with data from database.
Fill ComboBox with data from database.
API Declarations
' paste the code.
Rate Fill ComboBox with data from database.
(1(1 Vote))
'Open the Database
Set DB = DBEngine.Workspaces(0).OpenDatabase(App.Path & "\your database.mdb")
'Open table
Set RS = DB.OpenRecordset("your table here")
cboAnyName.Clear
While Not RS.EOF
cboAnyName.AddItem RS!AnyField
If RS.EOF Then
GoTo Exitna
End If
RS.MoveNext
Wend
Exitna:
RS.Close ' close table
Set RS = Nothing
End Sub
Fill ComboBox with data from database. Comments
No comments yet — be the first to post one!
Post a Comment