IDot11AdHocInterface::IsAdHocCapable method (adhoc.h)
Specifies whether a NIC supports the creation or use of an ad hoc network.
Syntax
HRESULT IsAdHocCapable(
[in, out] BOOLEAN *pfAdHocCapable
);
Parameters
[in, out] pfAdHocCapable
A pointer to a boolean that specifies the NIC's ad hoc network capabilities. The boolean value is set to TRUE if the NIC supports the creation and use of ad hoc networks and FALSE otherwise.
Return value
Possible return values include, but are not limited to, the following.
Return code | Description |
---|---|
|
The method completed successfully. |
|
The method failed. |
|
One of the parameters is invalid. |
|
The method could not allocate the memory required to perform this operation. |
|
A pointer passed as a parameter is not valid. |
Remarks
pfAdHocCapable can be set to FALSE for many reasons, including the following:
- Group policy prohibits the use of ad hoc networks on this interface
- The machine is configured to only connect to infrastructure networks, or the machine configuration disallows wireless connections
- The NIC does not support ad hoc networks
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows Vista [desktop apps only] |
Minimum supported server | Windows Server 2008 [desktop apps only] |
Target Platform | Windows |
Header | adhoc.h |