A AD108 Jul 29, 2006 #1 What would be the most direct approach to extracting just the last folder name from "ThisWorkBook.Path".
What would be the most direct approach to extracting just the last folder name from "ThisWorkBook.Path".
D Dave Peterson Jul 29, 2006 #2 Using InStrRev if you're using xl2k or above. Or looping from the last character to the first looking for the path separator (\ on windows).
Using InStrRev if you're using xl2k or above. Or looping from the last character to the first looking for the path separator (\ on windows).
S Steve Yandl Jul 29, 2006 #3 arrPath = Split(ThisWorkbook.Path, "\") strParentFldr = arrPath(UBound(arrPath)) Steve
A AD108 Jul 29, 2006 #4 Thanks, Dave Peterson said: Using InStrRev if you're using xl2k or above. Or looping from the last character to the first looking for the path separator (\ on windows). Click to expand...
Thanks, Dave Peterson said: Using InStrRev if you're using xl2k or above. Or looping from the last character to the first looking for the path separator (\ on windows). Click to expand...