So I have a very simple Access db with UserID, Office, Title,Show I want to Populate the list box with UserIDs that Match the Current user, also only add the user if they have Yes in the Show column.
I can get the current user but from there I'm just lost.
My thought process is
Rows = Table.rows.count
i=1
Run loop i to rows
if CurrentUser = Table(i,Column1(UserID))
UserOffice = Table(i,Column2(office))
end if
End loop
i=1
Loop i to rows
If Table(i,Column2(office)) = UserOffice then
If Table(i,Column4)= "Yes" Then
listbox1.items.add Table(i,Column1(UserID))
End if
end if
end loop
Just interacting with the Table is frustrating to me at this point. I would normally hard code everything but there are too many changes to push out a new app every time someone moves offices. It has been a 15 years since I used VB so everything I know from VB is deprecated or lost to the sands of time.
Please help!
What I have tried:
I have tried few things but at this point. Everything I google I just don't really understand.