Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
CgridList and highlighting
Message
General information
Forum:
Visual FoxPro
Category:
The Mere Mortals Framework
Miscellaneous
Thread ID:
00449639
Message ID:
00454013
Views:
31
>Did you try my recommendation on setting the column's Sparse property to .F.?

Yes. I found the problem, but I don't know how to resolve it. I have code in the AfterRowColChange() that enables and disables some buttons on the page. The code that is causing the problem is the following:

THIS.SETALL("DynamicBackColor", ;
"IIF(v_patnotes.rstatus = 'A', ;
THIS.BackColor,RGB(0,255,0))", ;
"Column")

I have a "Void" button on the page. It changes the v_patnotes.rstatus from 'A' (active) to 'V' (void). I want all voided (rstatus = 'V') items green, the selected item highlighted, and the active (rstatus = 'A') unselected records with the normal backcolor.

I want to turn the background green on all records that have a v_patnotes.rstatus of 'V' and leave them as normal for v_patnotes.rstatus of 'A'.

The problem is that in the cgridlist.sethighlight() the SetAll works in setting the highlight bar. But when I try doing the setall in the afterrowcolchange() after the highlight bar has been set, my setall overides that code and the highlight bar doesn't work. If I do my setall first, the sethighlight() code overwrites my "green bars" and I can't tell what records are voided.

I need a place to put code similar to the sethightlight() "RECNO() = THIS.nRecno". But I need to check each rstatus as I'm running through the setall instead of recno(), and set the dynamicbackcolor to green if v_patnotes.rstatus = 'V'. without messing up the highlight bar.

This is hard to explain! :)

This is the way it should look. I have ten records in this cgridlist. Three of the records have an Rstatus of 'V' and the rest an rstatus of 'A'. The voided records should all be green and the active records all normal except the one that is selected, which is highlighted.

Thanks for your help. Goober says Merry Christmas to you and yours!
Previous
Reply
Map
View

Click here to load this message in the networking platform