Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grid: losing the column's DynamicBackColor
Message
De
16/07/2002 18:27:26
Irv Adams
MSC Managed Care, Inc.
Floride, États-Unis
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00679377
Message ID:
00679406
Vues:
20
I have a class that colors the rows and 'current highlighted box' of a Grid in different combinations; although you use DynamicBackColor for the rows, you have to color the current box via the standard ForeGround/Background color properties of the Textbox (or whatever the control is)...

...also, the colors behave differently when you Click on a control within a grid as opposed to moving the cursor to that control or between controls (never figured this out...).

HTH,

-Irv.


>I lose the DynamicBackColor for some rows of a grid due to the addition of code in the WHEN clause of a combobox in the gridcolumn.
>
>In a form's INIT, i have the following to color this a grid column for a few particular grid rows:
>
>THISFORM.GrdTime.Column1.DynamicBackColor = "IIF( BETWEEN(tmptime.projfk,6,11), RGB(215,255,215), RGB(255,255,255))"
>
>
>I also need to makes these same rows readonly. In the WHEN clause of the gridcolumn's Combobox, i have the following:
>
>l_return = .t.
>SELECT tmptime
>IF BETWEEN(tmptime.projfk,6,11)
>   l_return = .f.
>ENDIF
>RETURN l_return
>
>
>This works fine with regard to being keeping the particular row cells readonly.
>
>The problem is that after i click on the combobox in column1 of the grid (cant change the value... which is good), the background turns white.
>
>I have tried placing the same "DynamicBackColor" command in the CLICK and LOSTFOCUS methods of the combo to turn back on the coloring of the row cells, without luck. Row colors remain white.
>
>If i comment out the code in the WHEN (and just RETURN), the color stays but the combo is no longer readonly.
>
>Any ideas?
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform