DNS Name App ID Requester Data Center Product Load Balancer {{element.name}} {{element.csiAppId}} {{element.requester}} {{element.dataCenter}} {{element.product}} {{element.loadBalancer}}I want to get selected datagrid row data from one html page and provide to another html page
both pages are in the same Clarity UI application and both have datagrid's to display the data that
that can be selected. See example code of first html to get data from below.
Asked
Active
Viewed 456 times
-1

lxjoyner
- 1
-
Welcome to StackOverflow, please format your question and code properly, so it can be understood by our members. Specifically use a code block for the code and remove the unnecessary indentation in the body of the question. Thanks! – santamanno Apr 17 '21 at 21:40
1 Answers
0
Datagrid row selections are stored in an array on the application side.
e.g
<clr-datagrid [(clrDgSelected)]="selected">
<-- ... -->
<clr-dg-row *clrDgItems="let user of users" [clrDgItem]="user">
<-- ... -->
</clr-dg-row>
<-- ... -->
</clr-datagrid>
selected
is the application array and two-way binding keeps it in sync with what a user selects vs what may be pre-selected when data is retrieved from the server.
I would look at preserving the info in the selected array so it can be shared across multiple routes. If you have more questions or want to discuss a working application create a simple stackblitz app that shows what you are trying to do. It will help me to help you if I can look at a running application.

hippeelee
- 1,788
- 1
- 10
- 21
-
I have 2 components : load-balancers.component and modify-vip.component. – lxjoyner Apr 22 '21 at 17:53
-
I have 2 components : load-balancers.component and modify-vip.component. I have a Datagrid in the load-balancers.component.html and a Datagrid in the modify-vip.component.html. I have the load balancer datagrid displaying data from a JSON file, which I can select each row and display the selected data in a module that is display when I perform a click command on a button located on the load balancer page. My problem is I don't know how to get the data to the modify-vip.component.html page to show the user the selected data from the load balancer html that was selected. – lxjoyner Apr 22 '21 at 18:05