# SalContext

Namespace: **PPJ.Runtime.Windows**

Assembly: **PPJ.Web.49** (4.9.0.0)

Synchronizes the Sys.hWndItem, Sys.hWndForm and Sys.hWndForm with the control handling the message.

{% tabs %}
{% tab title="C#" %}

```csharp
public class SalContext : IDisposable
```

{% endtab %}

{% tab title="VB.NET" %}

```visual-basic
Public Class SalContext
    Inherits IDisposable
```

{% endtab %}
{% endtabs %}

## Constructors

### ![](https://620403885-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrwxBtXkZ9hhQWYdbGhAV%2Fuploads%2FCKg4odMPj9bBKavXG5j4%2Finstance.png?alt=media\&token=2ac4a01b-785e-4197-b802-d5aae2250f90)SalContext(ctrl)

Constructs a new SalContext and pushes it on the stack.

| Name     | Type                                                      | Description                                  |
| -------- | --------------------------------------------------------- | -------------------------------------------- |
| **ctrl** | [Control](https://docs.wisej.com/api?q=wisej.web.control) | Target control on which to execute the call. |

### ![](https://620403885-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrwxBtXkZ9hhQWYdbGhAV%2Fuploads%2FCKg4odMPj9bBKavXG5j4%2Finstance.png?alt=media\&token=2ac4a01b-785e-4197-b802-d5aae2250f90)SalContext(ctrl, root)

Constructs a new SalContext and pushes it on the stack.

| Name     | Type                                                                  | Description                                  |
| -------- | --------------------------------------------------------------------- | -------------------------------------------- |
| **ctrl** | [Control](https://docs.wisej.com/api?q=wisej.web.control)             | Target control on which to execute the call. |
| **root** | [Boolean](https://docs.microsoft.com/en-us/dotnet/api/system.boolean) |                                              |

### ![](https://620403885-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrwxBtXkZ9hhQWYdbGhAV%2Fuploads%2FCKg4odMPj9bBKavXG5j4%2Finstance.png?alt=media\&token=2ac4a01b-785e-4197-b802-d5aae2250f90)SalContext(ctrl, locals)

Constructs a new SalContext and pushes it on the stack.

| Name       | Type                                                                | Description                                  |
| ---------- | ------------------------------------------------------------------- | -------------------------------------------- |
| **ctrl**   | [Control](https://docs.wisej.com/api?q=wisej.web.control)           | Target control on which to execute the call. |
| **locals** | [Object](https://docs.microsoft.com/en-us/dotnet/api/system.object) |                                              |

### ![](https://620403885-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrwxBtXkZ9hhQWYdbGhAV%2Fuploads%2FCKg4odMPj9bBKavXG5j4%2Finstance.png?alt=media\&token=2ac4a01b-785e-4197-b802-d5aae2250f90)SalContext(module)

Constructs a new SalContext and pushed it on the stack.

| Name       | Type                                                                               | Description |
| ---------- | ---------------------------------------------------------------------------------- | ----------- |
| **module** | [Assembly](https://docs.microsoft.com/en-us/dotnet/api/system.reflection.assembly) |             |

## Properties

### ![](https://620403885-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrwxBtXkZ9hhQWYdbGhAV%2Fuploads%2FCKg4odMPj9bBKavXG5j4%2Finstance.png?alt=media\&token=2ac4a01b-785e-4197-b802-d5aae2250f90)Control

[Control](https://docs.wisej.com/api?q=wisej.web.control): Returns the target control of the messages that created this context.

### ![](https://620403885-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrwxBtXkZ9hhQWYdbGhAV%2Fuploads%2FuqnVoSwYo95wh3jzDFPE%2Fstatic.png?alt=media\&token=ac9ad63b-db19-46a9-a325-36647205a41a)Current

[SalContext](https://docs.wisej.com/extensions/ppj.web.49/controls/ppj.runtime.windows.salcontext.md): Returns the current context at the top of the stack.

### ![](https://620403885-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrwxBtXkZ9hhQWYdbGhAV%2Fuploads%2FCKg4odMPj9bBKavXG5j4%2Finstance.png?alt=media\&token=2ac4a01b-785e-4197-b802-d5aae2250f90)Disposed

[Boolean](https://docs.microsoft.com/en-us/dotnet/api/system.boolean): Returns true if the SalContext has been disposed of (out of scope).

### ![](https://620403885-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrwxBtXkZ9hhQWYdbGhAV%2Fuploads%2FCKg4odMPj9bBKavXG5j4%2Finstance.png?alt=media\&token=2ac4a01b-785e-4197-b802-d5aae2250f90)Module

[Assembly](https://docs.microsoft.com/en-us/dotnet/api/system.reflection.assembly): Returns the module that created the control in context.

## Methods

### ![](https://620403885-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FrwxBtXkZ9hhQWYdbGhAV%2Fuploads%2FCKg4odMPj9bBKavXG5j4%2Finstance.png?alt=media\&token=2ac4a01b-785e-4197-b802-d5aae2250f90)Dispose()
