Posted: 8 Aug 2016 9:19 EDT Last activity: 4 Oct 2018 13:54 EDT
Record in a Grid is not selected when pySelected is set to true
We wanted to pre heighlight the row based on the previoulsy selected pySelected value in a Grid. In the second visit to an application screen.
To verify this we also tried the follwoing, system is not selecting the corresponding row.
1. Placed a text box and button on a screen
2. On button click, set user entered (text box) record's pySelected to true and rest to false. Refresh the section
2. Load the Grid (3 records in my case)
3. Enter 2 in the text box, click button
I have verified the property (pySelected) was set to true for the records number entered in the text box and rest to false. Also I see reload section in Tracer but recrod is not getting selected.
How can we achive this ?
Last update from SR-A87519: The requirement specified not a product bug - it’s a how-to implement type of question. FYI, in the repeat grid the “row” property panel need prompting for a “format” to apply on condition of pySelected=true. This “format” has to be defined in the skin and currently we don’t have the row formats to define in skin under “Grids” component setting.
***Updated by moderator: Lochan to add Category, edit post to remove proprietary information, tag SR details***
**Moderation Team has archived post**
This post has been archived for educational purposes. Contents and links will no longer be updated. If you have the same/similar question, please write a new post.
As per my understnading you are trying to select a particular column in a grid and displaying the same grid in the next screen. Now in the second screen(Screen B) you wan the focus to be set on the row which was selected in the first screen(Screen A).
So the solution which I am providing is based on the above understanding. Please rectify if I'm wrong
So this perhaps is a requirement because in PRPC we do not have an option to set the focus on a row of a grid "onload". So the below solution could be an approach with a few limitations
1) First configure a DataTransform on the column in grid of Screen A. Pass a parameter as below to DataTransform
2) In the DataTransform set the passed param to some property value.
3) Now in Screen B add the above set property(in above case RowIndex) as the first element in Screen B. Make this property as invisible and check Reserve space while hidden (so that the element is present in DOM ).
4) This property has the row's index value you set in previous grid (Screen A). Now as this is the first element that will be focused on load of Screen B configure "Focus" event on this property to set the focus to the row in our required Grid
So at runtime the usecase would be like below on the load of that section.
I have scenario to display the Work objects with Radio button in Grid Layout, so we can Select a Particular work object and proceed forward (to work on the case), i am getting a below error for after adding a pySelected property.
* Column bound to .pySelected, .pyID are marked as primary. More than one column cannot have the importance as primary
String value of a cell:
** .pySelected is not a valid Report-Definition Field"