FindNextVolumeMountPointA function (winbase.h)

Continues a mounted folder search started by a call to the FindFirstVolumeMountPoint function. FindNextVolumeMountPoint finds one mounted folder per call.

Syntax

BOOL FindNextVolumeMountPointA(
  [in]  HANDLE hFindVolumeMountPoint,
  [out] LPSTR  lpszVolumeMountPoint,
  [in]  DWORD  cchBufferLength
);

Parameters

[in] hFindVolumeMountPoint

A mounted folder search handle returned by a previous call to the FindFirstVolumeMountPoint function.

[out] lpszVolumeMountPoint

A pointer to a buffer that receives the name of the mounted folder that is found.

[in] cchBufferLength

The length of the buffer that receives the mounted folder name, in TCHARs.

Return value

If the function succeeds, the return value is nonzero.

If the function fails, the return value is zero. To get extended error information, call GetLastError. If no more mounted folders can be found, the GetLastError function returns the ERROR_NO_MORE_FILES error code. In that case, close the search with the FindVolumeMountPointClose function.

Remarks

After the search handle is established by calling FindFirstVolumeMountPoint, you can use the FindNextVolumeMountPoint function to search for other mounted folders.

The FindFirstVolumeMountPoint, FindNextVolumeMountPoint, and FindVolumeMountPointClose functions return paths to mounted folders for a specified volume. They do not return drive letters or volume GUID paths. For information about enumerating the volume GUID paths for a volume, see Enumerating Volume GUID Paths.

You should not assume any correlation between the order of the mounted folders that are returned with these functions and the order of the mounted folders that are returned by other functions or tools.

In Windows 8 and Windows Server 2012, this function is supported by the following technologies.

Technology Supported
Server Message Block (SMB) 3.0 protocol No
SMB 3.0 Transparent Failover (TFO) No
SMB 3.0 with Scale-out File Shares (SO) No
Cluster Shared Volume File System (CsvFS) No
Resilient File System (ReFS) No
 

SMB does not support volume management functions. CsvFS does not support adding mount point on a CSV volume. ReFS does not index mount points.

Note

The winbase.h header defines FindNextVolumeMountPoint as an alias which automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.

Requirements

Requirement Value
Minimum supported client Windows XP [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header winbase.h (include Windows.h)
Library Kernel32.lib
DLL Kernel32.dll

See also

FindFirstVolumeMountPoint

FindVolumeMountPointClose

Mounted Folders

Volume Management Functions