Quantcast
Channel: Windows PowerShell forum
Viewing all articles
Browse latest Browse all 21975

Getting the last name in a path as a variable

$
0
0

Lets say i have a path like C:/Myfolder/myfolder2/myfolder3/stuff

How do i get the folder with the name "stuff" out as a variable? not the hole path, but just the name of the last folder.


Viewing all articles
Browse latest Browse all 21975

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>