Hi All,
How can we apply a background color to a row based on cell value. If Cell value contains "Yes" then it has to highlight entire row.
I referred to the fallowing link but couldn't get the result.
https://www.outsystems.com/forums/discussion/72629/outsystems-data-grid-set-row-background-depending-on-cell-value/
Regards,
Vinod
Hello @Vinod Kumar R
Any particular reason why you're not using the conditional format instead?
Seems much easier to maintain and unlike custom code, it's supported by OutSystems.In your high-code approach you have two issues:
.wj-cell.background-red-lighter { background-color: var(--color-red-lighter); }
With these changes, it seems to work as expected:
Cheers,GM
Helo
You need to pass the row number and grid widget ID and basis on thaat you can add a css class to be appliead over there
Hope this helpsThanksTousif Khan
Hello @Tousif Khan , I tried using the Addclass as well but it needs to look for each row and highlight it.
Without sharing a sample oml it's much harder for the community to help and takes more time for everyone.Also, have you inspected the DOM in order to understand if the CSS class you're using is specific enough for its purpose (like mentioned here)?
Hi, @Gonçalo Martins,
Sharing the OML for reference.
I tried the JS but result are not in expected output
Thanks @Gonçalo Martins ,
It is working as expect.
Any particular reason why you're not using the conditional format instead? - Actully usecase is to apply the css on the ActionColumn