# SetParam function

Changes router processor configuration.

## Syntax

Delphi
C++

    function SetParam(
      St: DWORD;
      Value: DWORD
    ): Bool; stdcall;

    BOOL WINAPI SetParam(
      _In_  DWORD St,
      _In_  VOID Value
    );

## Parameters

St [in]

  The setting index, specifies a parameter to be changed.

  Value | Meaning
  --- | ---
  stEnableDebug
  0

  Enable or disable debug logging.

  Value must be type of BOOL.

  stDebugVerbosity
  1

  Set logging verbosity level.

  Value must be type of BYTE.

  stWriteLogCallback
  2

  Specify the WriteLog callback procedure.

  Value must be a pointer to the procedure start address.
  NULL also can be used to disable callback function.

  stSetTableDataCallback
  3

  Specify the SetTableData callback procedure.

  Value must be a pointer to the procedure start address.
  NULL also can be used to disable callback function.

  stUserAgent
  4

  Change default User-Agent string for HTTP client.

  Value must be a pointer to null-terminated string.

  stUseCustomPage
  5

  Enable or disable custom detection page usage.

  Value must be type of BOOL.

  stCustomPage
  6

  Change path to the custom detection page.

  Value must be a pointer to null-terminated string.

  stDualAuthCheck
  7

  Enable or disable dual authentication checking for Basic Authentication.

  Value must be type of BOOL.

  stPairsBasic
  8

  Load Basic Authentication pairs.

  Separate each pair by \r\n chars and separate username from password by \t char.

  Value must be a pointer to null-terminated string.

  stPairsDigest
  9

  Load Digest Authentication pairs.

  Separate each pair by \r\n chars and separate username from password by \t char.

  Value must be a pointer to null-terminated string.

  stUseProxy
  10

  Enable or disable proxy server usage.

  Value must be type of BOOL.

  stProxyIP
  11

  Specify proxy server IP address.

  Value must be a pointer to null-terminated string.

  stProxyPort
  12

  Specify proxy server port.

  Value must be type of WORD.

  stUseCredentials
  13

  Enable or disable custom authentication credentials usage.

  Value must be type of BOOL.

  stCredentialsUsername
  14

  Specify custom authentication user name.

  Value must be a pointer to null-terminated string.

  stCredentialsPassword
  15

  Specify custom authentication password.

  Value must be a pointer to null-terminated string.

  stReserved
  16

  Reserved for future use.

  stFilterRules
  17

  Load filter rules.

  A filter rule consists of place, mode and check string.

  Possible places:
  "body" - response body.
  "serv" - server name.
  "relm" - realm name.

  Possible modes:
  "eq" - string is equal to check string.
  "neq" - string is not equal to check string.
  "cnt" - string contains check string.
  "ncnt" - string doesn't contain check string.

  Separate each rule by \r\n chars and separate the fields by \t char.

  Value must be a pointer to null-terminated string.

Value [in]

  Value buffer. The type depends on specified setting index.

## Return value

If the function succeeds, the return value is nonzero.

If the function fails, the return value is zero.