what it is, i have saved data on a previous form into the database as words, but then i convert the words into its own unique ID. thus i want to load the data in another form, but i want to load the name of the item, not the ID.

but the problem is, ive made a program to do computer builds. so when i store data they all need to be apart of the same "group" e.g.

build number component ID
1 17
1 29
1 95
2 214
2 132
3 41

any ideas? heres what i have on the form load.

Private Sub Form_Load()

conConnection.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & _
 App.Path & "\" & "database97.mdb;Mode=Read|Write"

conConnection.CursorLocation = adUseClient
conConnection.Open
  
With cmdCommand
 .ActiveConnection = conConnection
 .CommandText = "SELECT * FROM Builds ORDER BY buildnumber ASC;"
 .CommandType = adCmdText
End With

With rstRecordSet
 .CursorType = adOpenStatic
 .CursorLocation = adUseClient
 .LockType = adLockOptimistic
 .Open cmdCommand
 .MoveFirst
 
End With

component = rstRecordSet!buildnumber
lstList.AddItem component

If component = 1 Then
lstList.AddItem "*"

End If

what result u r getting??

im only getting the first field into it instead of the whole build ID.

so i should be getting about 5 entrys into the listbox and im only getting 1. any ideas?

use a loop..

without a loop how u will get all the values..
u will get only one value which is the 1st one..

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.