Hi,
I want to Highlight Empty rows of Advanced grid widget in red color.
I wrote state definition for this and give it to Row Format property of grid but it applying to all grid rows.
Please let me know how to resolve this.
Thanks!
Solved! Go to Solution.
Hi @Pallavi
Here are 2 approach that could help:
- option1
add a new column to the grid that will be hidden for display
populate this column with a specific string (for example "empty") for the rows that are empty - this will require to write a service that scan the values before populating the grid.
Apply a state definition for the rows that have "empty" in that hidden column
-option 2
If some of the columns are of type number, define a state definition with default state being the red state for empty column, then an other state for <numeric column value> less than <a value higher than the max possible>
Apply that state to the rowFormat property. every rows with a value will have the second state while the one with no value will get the default state.
Hope this helps
Christophe
Hi @Pallavi
Here are 2 approach that could help:
- option1
add a new column to the grid that will be hidden for display
populate this column with a specific string (for example "empty") for the rows that are empty - this will require to write a service that scan the values before populating the grid.
Apply a state definition for the rows that have "empty" in that hidden column
-option 2
If some of the columns are of type number, define a state definition with default state being the red state for empty column, then an other state for <numeric column value> less than <a value higher than the max possible>
Apply that state to the rowFormat property. every rows with a value will have the second state while the one with no value will get the default state.
Hope this helps
Christophe
Hi Christophe,
Option1 is worked for me.
It will not work, only if "empty" string present in table.
So, added a column with Boolean basetype.
Thanks for the help!
Pallavi
Thank you I am pleased that it was helpful.
Would you mind marking the response as correct answer as this will helps other to find the solution ?
Thank you
Kind regards
Christophe