KernelBasePathCchStripPrefix Method

Removes the "\?" prefix, if present, from a file path.

Definition

Namespace: DevCase.Win32.NativeMethods
Assembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[DllImportAttribute("KernelBase.dll", CharSet = CharSet.Auto, BestFitMapping = false, 
	ThrowOnUnmappableChar = true)]
public static HResult PathCchStripPrefix(
	StringBuilder path,
	uint pathSize
)

Parameters

path  StringBuilder
A pointer to the path string.

When this function returns successfully, the same path string will have had the prefix removed, if the prefix was present.

If no prefix was present, the string will be unchanged.

pathSize  UInt32
The size of the buffer pointed to by path, in characters.

Return Value

HResult
Returns S_OK if the prefix was removed, S_FALSE if the path did not have a prefix to remove, or an HResult failure code.

Remarks

See Also