Concatenates two strings that represent properly formed paths into one path, as well as any relative path pieces. The directory path should be in the form of A:, B:, …, Z:. The file path should be in a correct form that represents the file part of the path. The file path must not be null, and if it ends with a backslash, the backslash will be maintained.
BOOL PathIsURL(
LPCTSTR pszPath)
Tests a given string to determine if it conforms to a valid URL format.
VOID PathQuoteSpaces(
LPTSTR pszPath)
Searches a path for spaces. If spaces are found, the entire path is enclosed in quotation marks.
This function takes a pair of paths and generates a relative path from one to the other. The paths do not have to be fully-qualified, but they must have a common prefix, or the function will fail and return FALSE.
For example, let the starting point, pszFrom, be"C:\FolderA\FolderB\FolderC", and the ending point, pszTo, be"C:\FolderA\FolderD\FolderE". PathRelativePathTo will return the relative path from pszFrom to pszTo as:"..\..\FolderD\FolderE". You will get the same result if you set pszFrom to "\FolderA\FolderB\FolderC"and pszTo to"\FolderA\FolderD\FolderE". On the other hand, "C:\FolderA\FolderB"and "A:\FolderA\FolderD"do not share a common prefix, and the function will fail.
VOID PathRemoveArgs(
LPTSTR pszPath)
Removes any arguments from a given path.
LPTSTR PathRemoveBackslash(
LPTSTR pszPath)
Removes the trailing backslash from a given path. Returns the address of the NULL that replaced the backslash, or the address of the last character if it’s not a backslash.
VOID PathRemoveBlanks(
LPTSTR lpszString)
Removes all leading and trailing spaces from a string.
VOID PathRemoveExtension(
LPTSTR pszPath)
Removes the file extension from a path, if there is one.
BOOL PathRemoveFileSpec(
LPTSTR pszPath)
Removes the trailing file name and backslash from a path, if it has them.
Replaces the extension of a file name with a new extension. If the file name does not contain an extension, the extension will be attached to the end of the string.