>Hi George,
>
>VFP9 has the new ICASE function for these cases:
>cColor=ICASE(VARTYPE(nVAL)='U','White',nVal=0,'Black',nVal<1,'Red','Green')
>Really cool, and somewhat readable also. At least we don't have to count the all the ( and ) anymore.
Tore,
Well, matching the parenthesis was pretty much taken care of in the IDE recently.< s >
I agree that ICASE() is cool, however, my point was that, like IIF() it can be misused, and thus, abused.
Would I like to see either removed? Nope, they're invaluable.
George
Ubi caritas et amor, deus ibi est