SCREEN LIFECYCLE

Transfer Data Between Screens 

In this learning content, we will examine the topic of transferring data from one screen to another screen in detail and in the context of an example scenario.

In this learning content, we will examine the topic of transferring data from one screen to another screen in detail and in the context of an example scenario.

Let's consider this issue through a scenario. We have a personnel list and we want to show the detailed record of a personnel we have selected from the list on another screen. This can be a full screen or Modal or Drawer screens. For this, we need to specify which record's detail we want to show on the screen where the detail will be shown. This is done by transferring a key between screens. For example, this key can be the registration or ID number for a staff member. The important thing about keys is that they should point to a single record.

Let's elaborate on the example further. Let's say there are records with registration numbers ID1, ID2, and ID3. ID1 is called John, ID2 is called Joe, and ID3 is called Mary.

ID No    FullName

ID1        John

ID2       Joe

ID3       Mary

It is possible to pass all the information of the selected record as a parameter to the detail screen; however, this is not a common or recommended method.
A better approach is to give only the key to the detail screen and query the database with this key on the detail screen.

The way to implement this process is to define a Screen Input to the detail screen. If we continue with the personnel list example, a Screen Input named Personnel ID and of Guid type can be defined to transfer the relevant key on the detail screen. Thanks to this Screen Input, when the screen is opened, the detailed information is accessed from the database and the information is displayed. This is the subject of the next learning content, Page Init.

In the personnel list screen, in order to access the details of the selected record, a Navigate action is connected to the OnClick event of the relevant record. In the Navigate action, the screen that will show the personnel detail is selected. Since a Screen Input named Personnel ID was previously defined in the personnel detail screen, this Screen Input is set as a parameter in the Navigate action. To pass the ID of the selected record as a parameter, the Current category in Symbol Picker is used. Current is used in the meaning of the related record and appears in OnClick events of objects containing multiple records such as Table, and GalleryView. For Personnel ID, ID is selected under the Current category.

Thanks to these operations, to summarize, the ID of the selected personnel is carried as a parameter to the detail screen. With this ID, the detail screen can access and display other information about the personnel.

In this learning content, we will examine the topic of transferring data from one screen to another screen in detail and in the context of an example scenario.

In this learning content, we will examine the topic of transferring data from one screen to another screen in detail and in the context of an example scenario.

Let's consider this issue through a scenario. We have a personnel list and we want to show the detailed record of a personnel we have selected from the list on another screen. This can be a full screen or Modal or Drawer screens. For this, we need to specify which record's detail we want to show on the screen where the detail will be shown. This is done by transferring a key between screens. For example, this key can be the registration or ID number for a staff member. The important thing about keys is that they should point to a single record.

Let's elaborate on the example further. Let's say there are records with registration numbers ID1, ID2, and ID3. ID1 is called John, ID2 is called Joe, and ID3 is called Mary.

ID No    FullName

ID1        John

ID2       Joe

ID3       Mary

It is possible to pass all the information of the selected record as a parameter to the detail screen; however, this is not a common or recommended method.
A better approach is to give only the key to the detail screen and query the database with this key on the detail screen.

The way to implement this process is to define a Screen Input to the detail screen. If we continue with the personnel list example, a Screen Input named Personnel ID and of Guid type can be defined to transfer the relevant key on the detail screen. Thanks to this Screen Input, when the screen is opened, the detailed information is accessed from the database and the information is displayed. This is the subject of the next learning content, Page Init.

In the personnel list screen, in order to access the details of the selected record, a Navigate action is connected to the OnClick event of the relevant record. In the Navigate action, the screen that will show the personnel detail is selected. Since a Screen Input named Personnel ID was previously defined in the personnel detail screen, this Screen Input is set as a parameter in the Navigate action. To pass the ID of the selected record as a parameter, the Current category in Symbol Picker is used. Current is used in the meaning of the related record and appears in OnClick events of objects containing multiple records such as Table, and GalleryView. For Personnel ID, ID is selected under the Current category.

Thanks to these operations, to summarize, the ID of the selected personnel is carried as a parameter to the detail screen. With this ID, the detail screen can access and display other information about the personnel.

Files

Yardımcı kaynaklar

Glossary