>Hello John
>I could not help but notice a small problem .....
>
>
>"IIF(RECNO('csrtmpFile') <> this.parent.Gridhighlighter1.nRecno,'',RGB(0,0,128))"
>
>change it to
>
>"IIF(RECNO('csrtmpFile') <> this.parent.Gridhighlighter1.nRecno,<b>RGB(255,255,255)</b>,RGB(0,0,128))"
>
Hi Hiten,
DynamicBackColor value (as a result of evaluating of IIF expression) can be empty string. In fact, that is DynamicBackColor default value. First versions of Grid Highlighter worked with expressions like:
"IIF(RECNO('csrtmpFile') <> this.parent.Gridhighlighter1.nRecno,
RGB(255,255,255),RGB(0,0,128))"
but it means you cannot set individual BackColor for the particular column.
Now to keep the BackColor setting it uses the expression
lcBackColorIIF = "IIF(RECNO('" + .cHostAlias + "') <> " + .cStorage + "," +
[''] + "," + .cHighBackColor + ")"
setting which geves the desired result. The '' value which you see in the debugger is the result on evaluation of assigning lcBackColorIIF to Column.DynamicBackColor. The expression like
lcBackColorIIF = "IIF(RECNO('" + .cHostAlias + "') <> " + .cStorage + "," +
'' + "," + .cHighBackColor + ")"
Sometimes the errors in DynamicBackColor expressions caused by underlying grid data.
Nick Neklioudov
Universal Thread Consultant
3 times Microsoft MVP - Visual FoxPro
"I have not failed. I've just found 10,000 ways that don't work." - Thomas Edison