Hey all,
I am on a new project, and I am trying to use listboxes for a queueing system.
What I have done is I have created a unique ID and when someone enters the queue that unique plus the string Person is added to a list box.
e.g. Person-1
What I need to do now is when another event occurs it needs to look in the queue to see which person is selected and then that ID is put into a table.
The trouble I am having is grabbing the string of the selected item in the list. I am using the following code to grab the ID but at the moment I am using a static string for the person, rather then the one from the list box.
Thanks for the help!
I am on a new project, and I am trying to use listboxes for a queueing system.
What I have done is I have created a unique ID and when someone enters the queue that unique plus the string Person is added to a list box.
e.g. Person-1
What I need to do now is when another event occurs it needs to look in the queue to see which person is selected and then that ID is put into a table.
The trouble I am having is grabbing the string of the selected item in the list. I am using the following code to grab the ID but at the moment I am using a static string for the person, rather then the one from the list box.
Code:
' Get Persons_ID and add to captured Data
Dim failed As Integer
Dim countdashes As Integer
Dim failedID As String
failedID = "Person-12"
countdashes = InStrRev(failedID, "-")
failed = right(failedID, (Len(failedID) - countdashes))
Thanks for the help!