Extract path: not sure if this is a bug or not.

Got a problem you cannot solve? Try here.
Post Reply
bokkie
Posts: 767
Joined: Sun Feb 08, 2009 6:30 am

Extract path: not sure if this is a bug or not.

Post by bokkie »

Copy and paste this code snippet:

Set Variable Q to C:\\Temp\\Fred\\\\Bob\\Horse
Replace \\\\ with \\: Q
MessageBox: Substituting \\\\ with \\ yields..., $Q$
Extract Parent Folder: Q
MessageBox: The parent folder is..., $Q$


The second message box displays C:\\Temp\\Fred. Is this correct given the full pathname in the variable?

I'm not sure if it's a bug or not but the parent folder displayed does not seem to be what I was expecting. I wonder if it's because the last component Horse is being interpreted as a filename, in which case the parent of Bob would be Fred?

EDIT: Scrap this! The last component is indeed the pathname so the parent folder displayed is correct. Doh!
Peter. Smartly dressed, he still resembles an unmade bed.
InstallAware MVP
Post Reply