|
-
Jun 15th, 2000, 01:11 AM
#1
Thread Starter
Member
Urgent help needed here
I have a recorset containing 2 cols of data 1D, and desc
how do i populate a combo box with the send coloumn?
thanks
-
Jun 15th, 2000, 01:41 AM
#2
Frenzied Member
Following is for a listbox, modify it accordingly.
Dim rsTmp As Recordset
Dim nLoop As Integer
Dim sListStr As String
frmMain.lstData(1).Clear 'dont want none of that bad data
Set rsTmp = database.OpenRecordset("SQL command", dbOpenSnapshot)
If rsTmp.EOF = False Then 'we collect the entries from the table
Do While Not rsTmp.EOF
sListStr = Format(rsTmp.Fields(1), "")
frmMain.lstData(1).AddItem sListStr, nLoop
nLoop = nLoop + 1
rsTmp.MoveNext
Loop
rsTmp.Close
End If
End Sub
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|