GetDefaultCompartmentId function

The GetDefaultCompartmentId function retrieves the default network routing compartment identifier for the local computer.

Syntax


NETIOAPI_API GetDefaultCompartmentId(void);

Parameters

This function has no parameters.

Return value

If the function succeeds, the return value is the default Compartment ID.

If the function fails, the return value is one of the following error codes.

Return codeDescription
NET_IF_COMPARTMENT_ID_UNSPECIFIED

The function failed to obtain a Compartment ID.

 

Requirements

Minimum supported client

Windows 10 [desktop apps only]

Minimum supported server

Windows Server 2016 [desktop apps only]

Header

Iphlpapi.h

Library

Iphlpapi.lib

DLL

Iphlpapi.dll

 

 

Show: