Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
get folder name
What would be the most direct approach to extracting just the last folder
name from "ThisWorkBook.Path". |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
get folder name
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). AD108 wrote: What would be the most direct approach to extracting just the last folder name from "ThisWorkBook.Path". -- Dave Peterson |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
get folder name
arrPath = Split(ThisWorkbook.Path, "\")
strParentFldr = arrPath(UBound(arrPath)) Steve "AD108" wrote in message ... What would be the most direct approach to extracting just the last folder name from "ThisWorkBook.Path". |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
get folder name
Thanks,
"Dave Peterson" wrote in message ... 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). AD108 wrote: What would be the most direct approach to extracting just the last folder name from "ThisWorkBook.Path". -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
how can i change my default working folder to a networked folder? | Excel Discussion (Misc queries) | |||
Check if folder exists, if yes just copy sheet in to folder? | Excel Programming | |||
How to decide folder-depth or How to select more folders/subfolders (folder-tree) ? | Excel Discussion (Misc queries) | |||
how can I specific a folder with wildcard criteria and excel will import all the correct files in that folder? | Excel Discussion (Misc queries) | |||
how can I specific a folder with wildcard criteria and excel will import all the correct files in that folder? | Excel Programming |