vba file from path
Dim path As String
path = "C:\Temp\data\myfile.txt"
Debug.Print Mid$(path, InStrRev(path, "\") + 1) ' -> myfile.txt
Are there any code examples left?
New code examples in category VBA
Dim path As String
path = "C:\Temp\data\myfile.txt"
Debug.Print Mid$(path, InStrRev(path, "\") + 1) ' -> myfile.txt