Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Highlight entire row on grid
Message
From
26/01/2003 07:56:16
 
 
To
26/01/2003 00:32:51
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00738413
Message ID:
00745520
Views:
35
Hi Steven.

What the hec is nRec? All you need is the custom property nRecNo to hold the record number of the current record in the grid's RecordSOurce. Did you add a custom proerty called nRecNo to your grid and initialize it to 0?

Also, I do not see where you have set up lnBgColor and lnFgColor.

Try copying and pasting this into the Init() of you grid class after making sure that you have the required nRecNo property added and initialized to 0:
DECLARE INTEGER GetSysColor IN "user32" INTEGER nIndex
lcBgColor = TRANSFORM( GetSysColor( 13 ) )
lcFgColor = TRANSFORM( GetSysColor( 14 ) )
lcExp = 'IIF( RECNO( This.RecordSource ) = This.nRecNo, ' + lcFgColor + ', ' + TRANSFORM( This.ForeColor ) + ' )'
This.SetAll( 'DynamicForeColor', lcExp, 'COLUMN' )
lcExp = 'IIF( RECNO( This.RecordSource ) = This.nRecNo, ' + lcBgColor + ', ' + TRANSFORM( This.BackColor ) + ' )'
This.SetAll( 'DynamicBackColor', lcExp, 'COLUMN' )
I know that this works because I just copied it from by base grid class < s >
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform