Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Setting individual grid cell color
Message
From
27/04/2000 14:28:08
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
27/04/2000 14:05:48
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00364206
Message ID:
00364216
Views:
31
>Hi all-
>
>I have a grid created using crosstab. Each cell (not row) relates to a record in a separate table. I would like to base the cell color on the contents of the cell related record. What is the best way to do this?
>
>Carlie


Carlie,
If you can specify what color it would be in a method than use method.

In init of grid you would say :
for each oColumn in this.Columns
   oColumn.DynamicBackColor = "thisform.mySetColor("+oColumn.Controlsource+")"
endfor
(Honestly I prefer grid custom method). In form's custom mySetColor you'd return suitable color.
This approach might be long if it's easy to directly define backcolor based on relations (ie: iif(Child.myField = blah blah...).
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform