a

Master-Detail (Single-to-Single)

In this example, a Master / Detail complete application, where we get an edit form of categories and products in that category will be developed.

   

To build this application will create two forms "Single Register". The first based on the categories table, which will be our Master application, and the second form will be based on the products table that will be the Detail Application.

 

Creating the Form Detail

1. Create a new application of simple type form based on the table products.

2. In the application menu to access the Layout folder and click on the item blocks.

   

3. Create one new block and change the settings of blocks according to the attached image.

   

4. In the application menu access the item "Fields Positioning."

   

5. Remove unnecessary fields and arrange them in blocks according to the image below.

   

6. Generate the source code of the detail form. For this click the Generate Source Code button on the toolbar ScriptCase.Gere o código fonte do formulário detalhe. Para isto clique no botão Gerar Código Fonte na barra de ferramentas do ScriptCase.

   

Creating the Master form

7. Create a new application of simple type form based on the categories table.

8. In the application menu to access the Layout folder and click on the item blocks.

   

9. Create two new blocks and blocks change the settings according to the attached image.

   

Creating the link between the Master form and the Detail form.

10. In the application menu to access the Master / Detail folder, then click New Master / Detail item

   

11. In the properties Name and Label inform products and click Create.

   

12. Select the detail and click the Proceed button.

   

13.In the next wizard step make the connection linking the categoryid fields of the two forms. Finally click the Save button.

   

Ok, the Master / Detail form is already created, but now we will arrange the fields in the form Master blocks

14. In the application menu open the item FIelds Positioning.

   

15. Remove unnecessary fields and arrange them in blocks according to the image below.

   

16. Run the Master application through the button in the ScriptCase toolbar.