Extracts the entire path except the last component.
|Path||A path with or without command line parameters.|
The directory portion of the path.
The GetDirectory service extracts the entire path except the last component. The directory will be returned with the backlash at the end. If Path already ends with a backslash, then the whole path is returned because a path ending in a backslash is assumed to be a directory.
Note. This method supports paths that contain command line parameters. In this case, command line parameters are simply ignored.
Result1 and Result2 will both be "C:\path1\path2\path3\". Result3 will be "C:\path1\path2\".