Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grid Row Select
Message
De
12/07/2000 05:54:24
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Divers
Thread ID:
00390749
Message ID:
00391115
Vues:
19
Hi Kelly.

>> I would like to click or double click on a row in a grid and have the entire row background chg color so the user is clear which row is selected. Is there a simple way to do this. <<

This code in the grid class's init (after adding a custom nRecNo property to your grid class):
This.nRecNo = RECNO( This.RecordSource )
This.SetAll( 'DynamicForeColor', ;
	'IIF( RECNO( This.RecordSource ) = This.nRecNo, RGB( 0, 0, 128 ), RGB( 0, 0, 0 ) )', 'COLUMN' )
This.SetAll( 'DynamicBackColor', ;
	'IIF( RECNO( This.RecordSource ) = This.nRecNo, RGB( 0,255,255 ), RGB( 255, 255, 255 ) )', 'COLUMN' )
And this in the grid class's AfterRowColChange:
Thisform.LockScreen = .T.
This.nRecNo = RECNO( This.RecordSource )
This.Refresh()
Thisform.LockScreen = .F.
Marcia
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform