Here is the code. Hopefully it is something simple. I'm still learning VB! I've been stuck on this one for quite a while! The combo box will not work correctly, however the list box does. I've tried dif combonations of the combo object and still no luck.
Thanks for the help.
VB Code:
'Populate UserList '============================== Dim rs As New ADODB.Recordset Dim cn As New ADODB.Connection Dim ITM As ListItem Dim cb As ComboItem cn.ConnectionString = frmMain.ConnectString cn.Open sql = "SELECT * FROM Users" rs.Open sql, cn, adOpenForwardOnly, adLockOptimistic ListView1.View = lvwReport ListView1.ColumnHeaders.Add 1, , "Autonumber" ListView1.ColumnHeaders.Add 2, , "User" With rs Do Until rs.EOF = True Set ITM = ListView1.ListItems.Add(1, "", Trim(!autonumber)) Set cb = cmbAssigned.AddItem(rs.Fields("product")) ITM.SubItems(1) = IIf(IsNull(!User), "", Trim(!User)) .MoveNext Loop End With 'Populate Priority 'Populate Status




Reply With Quote