Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Changing the backcolor in a Grid
Message
De
09/01/2002 13:33:17
Henry Ravichander
RC Management Systems Inc.
Saskatchewan, Canada
 
 
À
08/01/2002 21:34:42
Wilfred Chan
Bnp Paribas Hong Kong Branch
Hong Kong, Hong Kong
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00602300
Message ID:
00602612
Vues:
28
Hi Wilfred:

I tried this code but got the following VFP message:

"Expression is invalid. Use a valid expression for DYNAMICBACKCOLOR property"

- Ravi

>Hi,
>It can be done by using "DynamicBackColor".
>e.g.
>WITH THIS.grid1
> FOR i=2 TO 8
> oCol=EVAL(".Column"+LTRIM(STR(i)))
> oCol.DynamicBackColor="IIF(ATC('BLOCK',T1.F1)>0,RGB(255,0,0),RGB(0,0,255))"
> NEXT
>ENDWITH
>
>Also see other "Dynamic" methods.
>
>:) Wilfred
>
>
>>Hi all:
>>
>>I have a grid displaying 8 columns. I would like to achieve the following:
>>
>>- columns 2-8 should display background color (say blue)
>>- if the text in any of the 2-8 columns is = "*BLOCK*", then, that cell in the grid should have a backcolor of (say red), else, the backcolor should be (say yellow)
>>
>>Any suggestions would be appreciated. TIA
>>
>>- Ravi
- Ravi

True greatness consists in being great in little things.
- Charles Simmons
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform