3.9.4.7 GetProcessMode (Opnum 9)

The GetProcessMode method retrieves the application execution mode for the IIS server.

 HRESULT GetProcessMode(
   [out] DWORD* pdwMode
 );

pdwMode: A pointer to an unsigned 32-bit integer that receives the server's application execution mode. This parameter MUST be set to one of the following values.

Value

Meaning

0x00000001

The server is hosting applications in application pools.

0x00000000

The server is hosting applications in the IIS server process and child processes.

Return Values:  A signed 32-bit value that indicates return status. If the method returns a negative value, it failed. If the 12-bit facility code (bits 16–27) is set to 0x007, the value contains a Win32 error code in the lower 16 bits. Zero or positive values indicate success, with the lower 16 bits in positive nonzero values containing warnings or flags defined in the method implementation. For more information about Win32 error codes and HRESULT values, see [MS-ERREF].

Return value/code

Description

0x00000000

S_OK

The call was successful.

The opnum field value for this method is 9.

When processing this call, the server MUST do the following:

  • If the call succeeds, return the current hosting mode defined by the server in the pdwMode parameter.