I think it should be something like
colorvalue = [thisform.setpolicygridcolor(.recordsource,cField)]
.Columns(nColIndex).dynamicbackcolor = colorvalue
and it should be to be set only once when grid is set.
>I have a form class which contains a grid and the grid is populated during runtime. That all works fine. We have decided to set a cell's backcolor depending on the value in the underlying table. I am overlooking something in the process though because I keep receiving the message that the datatype is invalid for this property when I attempt to set the color for the column. My goal is to actually set the backcolor of the cell on the fly to highlight specific values.
>
>Here is an overview of the code in the form class method:
>
<snip>
--sb--