# Error Constructor

## Overloads

| [Error(Int32, String, String)](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Sense.JsonRpc.MethodInvocationException.Error.-ctor.htm#Qlik_Sense_JsonRpc_MethodInvocationException_Error__ctor_System_Int32_System_String_System_String_) |  | Initializes a new instance of the Error class with a specified error code, message and optional parameter. |
| --- | --- | --- |

[](https://help.qlik.com/en-US/sense-developer/Subsystems/NetSDKAPIref/Content/Qlik.Sense.JsonRpc.MethodInvocationException.Error.-ctor.htm) [](https://help.qlik.com/en-US/sense-developer/Subsystems/NetSDKAPIref/Content/Qlik.Sense.JsonRpc.MethodInvocationException.Error.-ctor.htm)

## Error(Int32, String, String)

Initializes a new instance of the Error class with a specified error code, message and optional parameter.

### Declaration

```

          public Error(int errorCode = 0, string message = "", string parameter = "")
    
  
```

### Parameters

| Type | Name | Description |
| --- | --- | --- |
| System.Int32 | errorCode | The specified error code |
| System.String | message | The optional error message |
| System.String | parameter | The optional error parameter |