function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Arun KArun K 

Row color change after refresh Page

Hi,

I am having this requirement.

I have pageblocktable where I have rows initially.
With button I add new row in table and then I want to have that row in one color and If user refreshes, I want that row to got to other color.
Please give directions in this.

Thanks
Arun K
Suraj GharatSuraj Gharat
Hi Arun,

Create a wrapper class that wraps your record (Or whatever the row values you want to show) with its color information into it. Your controller will have the list of this wrapper class, and the same list will be bound to pageblocktable on Visualforce page. When you initially load the data, you will set same colour information for all rows. However when user adds any new row then that row's colour will be set to something different value.


HTH,
Suraj