Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Highlighting cells only in a grid
Message
From
05/08/2006 07:56:52
 
 
To
05/08/2006 04:59:04
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01143160
Message ID:
01143186
Views:
13
This message has been marked as the solution to the initial question of the thread.
However, I'm getting an error after adapting your code as follows:

It would certainly have been more helpful if you had told us what error you were getting < s >.


oGrd.Column7.DynamicBackColor = [IIf(ogrd.column7.text1.value<40,RGB(255,0,0),RGB(255,255,255))]

Where is this code? Is it in the form? Why don't you just move it to the grid's Init() and ammend as follows:
This.Column7.DynamicBackColor = [IIf( << the field in the RecordSource Bound to column 7 >> <40,RGB(255,0,0),RGB(255,255,255))]
You want the condition to refere to the data in the grid's RecordSOurce, not its embedded controls.

I am also assuming that the error has something to do with the fact that VFP has no clue what oGrd is. If the code is in the form, you have to use the fully qualified containership hierarchy to refer to objects on it: Thisform.oGrd.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform