# Show Window

The block allows you to create your own windows (forms) and display them in modal and non-modal modes, including asynchronously relative to the script flow. If a selector is specified, the coordinates of the created window will be bound to a control in another application.

To create and edit your window, use the "Edit..." button inside the block, and to create reusable windows - use the "Window Editor" button on the main toolbar.

Each call to this block either shows or updates the data of the window (if the window is already on the screen). In the case of a non-modal window, a repeated call to the "Show Window" block allows dynamically updating controls in the window and variables that are bound to the window elements.

The values of each control, as well as user actions in the window, can be bound to changes in the values of selected variables, and vice versa - changing the values of variables leads to changes in the values of the corresponding controls. This functionality allows for the development of branching dialog and expert systems, Robot settings windows, interactive hints and assistants, as well as entire multi-window applications within the Robot script.

<table data-header-hidden><thead><tr><th width="181.58331298828125" valign="top"></th><th width="288.00006103515625" valign="top"></th></tr></thead><tbody><tr><td valign="top">Configuration</td><td valign="top">[Text/Object] Configuration string. To edit the value, use the "Edit" button inside the block.</td></tr><tr><td valign="top">Window Object</td><td valign="top">[Object] Variable with the window object. The window object can be obtained from the previous "Show Window" block in the script, and this is relevant for displaying the window in non-modal mode.</td></tr><tr><td valign="top">Modal</td><td valign="top">When enabled, the window will be shown as modal. Otherwise, control will immediately return to the script after displaying the window.</td></tr><tr><td valign="top">Selector</td><td valign="top"><p>[Selector] Identifier of the element to which the window will be bound when displayed.</p><p>If the selector is not specified, the property is ignored. If the element is found, the window will be displayed according to the specified settings in the properties of this block. If the selector is not found, the window will be displayed in the center of the screen.</p></td></tr><tr><td valign="top">Process ID</td><td valign="top"><p>[Link] Variable that stores the Process ID. Indicates which application to work with.</p><p>If the specified application is minimized, or its window is covered by other windows, it will be brought to the foreground. When working with browsers, the Process ID additionally specifies the specific browser tab that the block should work with.</p><p>If the property is left empty, or if the Process ID variable was not previously assigned at the time of launching the application or opening the browser, the application and browser tab will be determined from the content of the corresponding selector string.</p><p>The Process ID can be obtained, for example, using the "Launch Application" or "Get Process" blocks.</p></td></tr><tr><td valign="top">Anchor Corner</td><td valign="top"><p>Select the value of the window's anchor corner.</p><p>If the selector is specified, the value indicates the binding of the top-left corner of the window to the corner of the found element (in this case, the value "Default" will indicate the center of the element).</p><p>If the selector is specified but not found, the window will be displayed in the center of the screen regardless of the property value.</p><p>If the selector is not specified, the property indicates the binding of the window to the working area of the main screen.</p></td></tr><tr><td valign="top">X Offset</td><td valign="top"><p>[Number] X coordinate offset when displaying the window.</p><p>If the selector is not specified and the anchor corner is "Default", and this property has a value, then this value will be considered absolute coordinates for displaying the window.</p></td></tr><tr><td valign="top">Y Offset</td><td valign="top"><p>[Number] Y coordinate offset when displaying the window.</p><p>If the selector is not specified and the anchor corner is "Default", and this property has a value, then this value will be considered absolute coordinates for displaying the window.</p></td></tr><tr><td valign="top">Element Event</td><td valign="top"><p>[Text] Generated event from the element on the form.</p><p>Value format: "ControlName.EventName".</p><p>If a button on the form has a DialogResult value, that value will be indicated in this property.</p><p>For example, "OK" or "Cancel".</p></td></tr><tr><td valign="top">Window Object</td><td valign="top">[Object] Returns the created window object. This property is useful if showing the window without using modality. For this, specify the variable from this property in the next block. In this case, the data in the window will be updated without creating a new instance of the window.</td></tr><tr><td valign="top">Error Handling Level</td><td valign="top"><p>Select the error handling level. Possible values:</p><ul><li>"Default" - by default;</li><li>"Ignore" - errors are ignored;</li><li>"Handle" - errors are handled.</li></ul><p>If "Default" is selected, the value from the "Start" block of this diagram will be used.</p></td></tr><tr><td valign="top">Message Level</td><td valign="top"><p>Select the message level that the blocks will output during operation. Possible values:</p><ul><li>"Default" - by default;</li><li>"Release" - output is disabled;</li><li>"Debug" - main information output;</li><li>"Detailed" - detailed information output.</li></ul><p>If "Default" is selected, the value from the "Start" block of this diagram will be used.</p></td></tr><tr><td valign="top">Error Text</td><td valign="top">[Text] Returns detailed information about the error in case of incorrect execution of the block's work.</td></tr></tbody></table>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.sherparpa.ru/en/sherpa-rpa/sherpa-designer/spravochnik-blokov/dialogovye-okna-dialogs/pokazat-okno-invokeshowwindow.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
