Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Grid Highlighter
Message
 
À
15/02/2001 11:09:58
Jack Liebschutz
Black Mountain Software
Polson, Montana, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Produits tierce partie
Divers
Thread ID:
00476309
Message ID:
00476347
Vues:
21
>This is such a cool product. Thanks Nick, but a question.
>I have a grid where I would like to have a couple of
>the columns not highighted. I basically have a grid within a grid, where
>the parent columns use fore/back colors to go invisible when they repeat.
>The highlighter is destroying this behaviour. Any ideas?
>
>Thanks again.
>
>Jack
>
>P.S. Nick I will try to get you a Montana souvenir when it stops snowing.

Thank you Jack.

Since the main purpose of Grid Highlighter is to highlight the entire row, the SetAll method used throughout the code so it always highlights all columns.
In your case yopu need to highlight all columns but one (or two). So, you have to customize the code in the Grid Highlighter instance on the form.

That's what the hook methods OnBeforeHighlight_Row() and OnPostHighlight_Row() are for. To disable the highlighting for two columns in your case you may place the following code into OnBeforeHighlight_Row() method of GridHighlighter instance:
*** OnBeforeHighlight_Row() method 
*get your grid name
lcHost = THIS.cHostname
* Reset the DynamicBackColor (or other Dynamic... expression) 
* for the particular columns, say columns 3 and 5
THIS.PARENT.&lcHost..Column3.DYNAMICBACKCOLOR = '[]' 
THIS.PARENT.&lcHost..Column5.DYNAMICBACKCOLOR = '[]'
There is another part of code which handles the appearance of the selected cell (.lSelectOnEntry) property, but try this code first and tell me if it works for your case.
Nick Neklioudov
Universal Thread Consultant
3 times Microsoft MVP - Visual FoxPro

"I have not failed. I've just found 10,000 ways that don't work." - Thomas Edison
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform