Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Different color row highlights for diff. criteria on a g
Message
From
07/08/2006 07:21:56
 
 
To
07/08/2006 04:33:05
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01143188
Message ID:
01143388
Views:
10
Hi Tore,

Thanks very much for your reply.

I have entered the following code in a new method called 'getAvg' of my form:
avg = ((dailywork.nmen+dailywork.nwmn+dailywork.nadl)/(pkg.nripe+pkg.ngreen))
DO CASE
	CASE avg >= 0 and avg < 20
	 nColor = RGB(0,0,100)
	CASE avg >= 20 and avg < 30
	 nColor = RGB(100,0,100)
	CASE avg >= 30 and avg < 40
	 nColor = RGB(200,0,100)
	CASE avg >= 40 and avg < 60
	 nColor = RGB(0,100,100)
	CASE avg >= 60 
	 nColor = RGB(0,200,100)
ENDCASE

RETURN ncolor
And in the Init of the Grid...
ogrd.SetAll("DynamicBackColor", "getAVG([Dailywork.nmen+Dailywork.nwmn],;
[Pkg.nripe+pkg.ngreen])", "Column")
Will you be able to help me as to where I've gone wrong?

Regards,

Steve
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform