--- title: "Using A Sub-Dialog Button To Update Data On Main Form" slug: "using-a-sub-dialog-button-to-update-data-on-main-form" updated: 2021-03-12T15:05:27Z published: 2021-03-12T15:07:13Z canonical: "documentation.decisions.com/using-a-sub-dialog-button-to-update-data-on-main-form" --- > ## Documentation Index > Fetch the complete documentation index at: https://documentation.decisions.com/llms.txt > Use this file to discover all available pages before exploring further. # Using A Sub-Dialog Button To Update Data On Main Form Example Lab ArticleWhile Example Lab projects are resources for public use, articles and assets are not actively maintained. Screenshots and features are from the specified version below. These references may become dated as new versions are released. --- ## Overview | ## Example Lab Details | | --- | | **Version** | 6.12.1 | | **Root Folder** | Example Lab- Using Sub-Dialog To Modify Data On Main Form | | **Modules** | None | | **Dependencies** | None | This example demonstrates how to use a Sub-Dialog button to update data on the Main Form. --- ## Explanation The **Main Form** contains two textboxes :one for **Name** and one for **Email**. These fields are disabled and default data is already entered. The **Sub-dialog button**, "Update", will be used to modify the **Name** and **Email** fields on the **Main Form**. The **Sub-Dialog Flow** takes in the **Name** and **Email** from the Main Form. The **Sub-Dialog Form** will display the **current inputs** on the Main form and also has textboxes that users can use to modify the **Name** and **Email**. On the **Update output** path the Flow will output the updated Name and Email data. On the **Cancel output** path there is no output data. If the user updates the data, the changes will be reflected on the Main Form. To test this example, run the **"Main Flow"** Flow. Reference Articles[Sub Dialog Data Flow](https://documentation.decisions.com/docs/sub-dialog-data-flow) ![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/Main%20Form(2).png) ![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/sub%20dialog%20flow(1).png) ![](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/sub%20dialog%20Form.png) --- ## Project Download The examples attached were developed to be instructional and were not developed as officially supported components. For more information or to engage our service team to develop fully supported, production quality solutions, please contact services@decisions.com. Import the project below to a Decisions environment on version 6.12.1 or later using our [Importing/Exporting](https://documentation.decisions.com/docs/exporting-and-importing-overview) article. [ExampleLab[UsingSubDialogToModifyDataOnMainForm].zip](https://cdn.document360.io/6ef8bcc1-6489-4486-9ad1-83acff7e5df0/Images/Documentation/ExampleLab%5BUsingSubDialogToModifyDataOnMainForm%5D.zip) ---