Removes all parts of the path except for the root information
#include <WinAPIShPath.au3>
_WinAPI_PathStripToRoot ( $sFilePath )
$sFilePath | The path to be converted. |
Success: | The string contains only the root information taken from that path. |
Failure: | Empty string. |
Search PathStripToRoot in MSDN Library.
#include <WinAPIShPath.au3>
Local $sPath = 'C:\Documents\Test.txt'
ConsoleWrite('Before: ' & $sPath & @CRLF)
ConsoleWrite('After : ' & _WinAPI_PathStripToRoot($sPath) & @CRLF)