I am trying to reference a value from a listbox as a string so that I can use that as a filename in a sub. I need to unzip all the file names that I have in a table, I am using that tables rowsource data in a listbox and from the listbox I want to copy the filename and use it in an unzip sub. Any ideas?
My code is:
fnameString = Me.List0.Value
fname = CurrentProject.Path & "\" & fnameString
'CurrentProject.Path & "\Files.zip" works but I need to replace the static filename with the referenced name from the listbox. Any help would be appreciated.
My code is:
fnameString = Me.List0.Value
fname = CurrentProject.Path & "\" & fnameString
'CurrentProject.Path & "\Files.zip" works but I need to replace the static filename with the referenced name from the listbox. Any help would be appreciated.