I have a folder C:\the Junction\test
, which is actually a junction, and the real path (target) is D:\the real\path\to\the folder
.
How can I find out that real target path in VBScript?
I have a folder C:\the Junction\test
, which is actually a junction, and the real path (target) is D:\the real\path\to\the folder
.
How can I find out that real target path in VBScript?
Give a try this code:
I'm not aware of a way to get this information with plain VBScript, but you can shell out to
fsutil
to extract this information:Change the pattern to
Substitute Name:\s+\\\?\?\\(.*)
if you want to exclude the leading\??\
from the path.