Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Dynamic Color in Grid
Message
De
22/07/1999 15:24:15
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Dynamic Color in Grid
Divers
Thread ID:
00244921
Message ID:
00244921
Vues:
57
I have a grid on a form that sets the dynamicbackcolor and dynamicfore color in the init event of the grid as follows:

public grno
grno = recno()
this.setall('DynamicBackColor','iif(recno()=grno,rgb(128,128,255),rgb(255,255,255))','Column')
this.setall('DynamicForeColor','iif(deleted(),rgb(255,0,0),rgb(0,0,0))','Column')

In the afterrowcolchange event I have:

grno = recno()
this.refresh()

The results of this is that when the user moves through the records in the grid the entire row shows with the background color (128,128,255) and all the rows have the fore color of 0,0,0 except for deleted records which are 255,0,0.

All of this is fine until the user clicks in the grid. When they click the back color changes to white(255,255,255) and the fore color to black (0,0,0). Is there a way to make the colors stay the same as what is set dynamically?
Mark Johns
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform