Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Grid backclor in VFP8

Status
Not open for further replies.

kmagy

MIS
Oct 21, 2003
38
JO
Hi every body
Iam trying to set back color of the records in a grid based on customer balance, Iam using the following code
but it produces the error 'Unrecognized command verb'

DODEFAULT()
WITH THIS
.SetAll("DynamicBackColor", ;
&quot;IIF(BALANCE<0, RGB(255,170,213), ;
IIF(BALANCE=0, RGB(255,255,255), ;
IIF(BETWEEN(BALANCE1,500), RGB(255,255,168), ;
IIF(BETWEEN(BALANCE,501,1000), RGB(210,210,210), ;
IIF(BETWEEN(BALANCE,1001,3000), RGB(201,255,144), ;
IIF(BALANCE>3000, RGB(136,196,255), ;
RGB(255,255,255))))))))&quot;,&quot;COLUMN&quot;)
ENDWITH

Please let me know what is wrong with it
Thanks in advance


 
It is working fine when there is (5 IIF statments)
but when adding the sixth IIF statment it produces the error
 
kmagy

IIF(BETWEEN(BALANCE1,500)

Is this one right? Or is it a typo?

Mike Gagnon

If you want to get the best response to a question, please check out FAQ184-2483 first.
 
It is written correclty in the form but when I write it here I wrote it without comma by mistake
Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top