Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Column Data ForeColor
Message
 
 
À
29/10/2009 02:50:12
Paul Ong
Knights of Christ Foundation
Californie, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01431831
Message ID:
01432183
Vues:
54
>I was very curios so what i did was i put in a button procedure. and then i would reverse its effect on the next click, however, on click i get an error message, something wrong with the code below?
>
>error:
>Expression is invalid,
>
>btw. so you mean i can call the same proc over and over again?
>
>thisform.bASGRID1.Column7.DynamicForeColor=[IIF(tPoDetail.solastwk=0,IIF(MOD(tPoDetail.nrowid,2)=0,RGB(228,228,288),RGB(255,255,255)),RGB(0,0,255))]
>
>thanks in advance...
>

Agnes found a typo in your RGB - it should be RGB(228,228,228). You don't need to put it in procedure or button - you need to do it only once in either grid or form's Init.

If you want ti verify the expression, then
lnColor = IIF(tPoDetail.solastwk=0,IIF(MOD(tPoDetail.nrowid,2)=0,RGB(228,228,228),RGB(255,255,255)),RGB(0,0,255))
=messagebox('Color on this row is ' + transform(lnColor)) && to verify
If it's not broken, fix it until it is.


My Blog
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform