Dim dlgOpen As FileDialog sFileName = "" set dlgOpen = Application.FileDialog FileDialogType:=msoFileDialogFilePicker) With dlgOpen .Filters.Clear .InitialFileName = sQualityPath .Filters.Add Description:="All files (*.*)", Extensions:="*.*" .AllowMultiSelect = False .title = "Select EXISTING quality document" If .Show = -1 Then sFileName = .SelectedItems(1) 'extract filename from pathname sFileName = UCase(Mid(sFileName, Len(sQualityPath) + 1)) '.SelectedItems(1) = "" Set dlgOpen = Nothing Else Beep MsgBox "No file selected", vbInformation, "Creat draft of next version of quality document" Set dlgOpen = Nothing Main End If End With
Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.
”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.