HostEnumerateShares Method (String, ShareType, Boolean) |
Enumerates Server Message Block (SMB) shares from the specified host.
Namespace:
Alphaleonis.Win32.Network
Assembly:
AlphaFS (in AlphaFS.dll) Version: 2.2
Syntax public static IEnumerable<ShareInfo> EnumerateShares(
string host,
ShareType shareType,
bool continueOnException
)
Public Shared Function EnumerateShares (
host As String,
shareType As ShareType,
continueOnException As Boolean
) As IEnumerable(Of ShareInfo)
public:
static IEnumerable<ShareInfo^>^ EnumerateShares(
String^ host,
ShareType shareType,
bool continueOnException
)
static member EnumerateShares :
host : string *
shareType : ShareType *
continueOnException : bool -> IEnumerable<ShareInfo>
Parameters
- host
- Type: SystemString
The DNS or NetBIOS name of the specified host. - shareType
- Type: Alphaleonis.Win32.NetworkShareType
The type of the shared resource to retrieve. - continueOnException
- Type: SystemBoolean
suppress any Exception that might be thrown as a result from a failure, such as unavailable resources.
Return Value
Type:
IEnumerableShareInfoIEnumerableT shares from the specified host.
Remarks This method also enumerates hidden shares.
See Also