Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Refresh A Listbox
Message
General information
Forum:
Microsoft Office
Category:
Access
Title:
Refresh A Listbox
Environment versions
Microsoft Office:
Office XP 2002
Miscellaneous
Thread ID:
01357832
Message ID:
01357832
Views:
55
I am loading a listbox using this code. When pass in the salesperson key, the listbox is not loaded:
Private Sub LoadSelectedList(iSalesPersonId As Integer)

    Dim strQuery As String
                    
    strSQL = "SELECT Pk_Id, Name " _
                & "FROM tblClient " _
                & "WHERE tblClient.Pk_Id IN " _
                & "(SELECT fk_Client " _
                & "FROM tblSalespersonClient " _
                & "WHERE fk_Salesperson = " & iSalesPersonId & ")"
        
    lstSelected.RowSourceType = "Table/Query"
    lstSelected.RowSource = strSQL
    lstSelected.Requery

End Sub
What am I doing wrong?
Everything makes sense in someone's mind
public class SystemCrasher :ICrashable
In addition, an integer field is not for irrational people
Reply
Map
View

Click here to load this message in the networking platform