Export (0) Print
Expand All
Expand Minimize
This topic has not yet been rated - Rate this topic

IsNetDrive function

[This function is available through Windows XP Service Pack 2 (SP2) and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows. Use GetDriveType or WNetGetConnection instead.]

Tests whether a drive is a network drive.

Syntax


int IsNetDrive(
  _In_  int iDrive
);

Parameters

iDrive [in]

Type: int

An integer that indicates which drive letter you want to test. Set it to 0 for A:, 1 for B:, and so on.

Return value

Type: int

This function returns one of the following values.

Return valueDescription
0

The specified drive is not a network drive.

1

The specified drive is a network drive that is properly connected.

2

The specified drive is a network drive that is disconnected or in an error state.

 

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Shlobj.h

Library

Shell32.lib

DLL

Shell32.dll (version 5.0 or later)

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.