Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
GRID HEADERS
Message
From
13/12/1996 10:16:21
 
 
To
13/12/1996 02:29:34
General information
Forum:
Visual FoxPro
Category:
Other
Title:
Miscellaneous
Thread ID:
00014895
Message ID:
00015028
Views:
38
>I thought of that too. Maybe a dum question , but how does this work?

Ok, here's another fantastic trick. :)

In this example, Recherche is the object name of a grid. Whenever the user changes the order of the grid alias, we reset all the grid header backcolor property to the default and put the actual field order to a different color. aOrdre array contains a list of all the field names in the grid and tnBar is the actual parameter we pass to this method to know which one to highlight.
ThisForm.Recherche.SetAll('BackColor',RGB(192,192,192),'Header')
FOR lnCompteur=1 TO ThisForm.Recherche.ColumnCount
   IF ThisForm.Recherche.Columns(lnCompteur).ControlSource==;
     ThisForm.Recherche.RecordSource+'.'+ALLTRIM(ThisForm.aOrdre[tnBar,3])
   ThisForm.Recherche.Columns(lnCompteur).Header1.BackColor=RGB(255,255,0)
   ENDIF
NEXT
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Previous
Reply
Map
View

Click here to load this message in the networking platform