Hi M
No. I meant: you've already found out that it is "N", so why then, in the same If statement, do you test for it to be ANYTHING else - 10 OR "10" - you know it's "N"
but I've just seen the TYPE() function, which I missed before (desert blindness :-)
TYPE() doesn't need EVAL() too.
So you're testing for a controlsource that is numeric?
>hi,
>if you mean i must change it as
>IF TYPE(EVALUATE(lcCS)) = '10'
>
>i get the same error
>
>
>
>>>hi all,
>>>any idea
>>>
>>>i put this code under at mygrid event inti, error message
>>>expretion is invalid.use avalid expression for dynamic back color property
>>>
>>>FOR EACH loColumn IN this.Columns
>>> lcCS = 'this.' + loColumn.Name + '.ControlSource'
>>> IF TYPE(EVALUATE(lcCS)) = 'N'
>>
>>You've just evaluated lcCS to be 'N'
>>
>>> loColumn.DynamicBackColor = [IIF(EVALUATE(] + lcCS + [) < 10, RGB(225, 128, 128), RGB(128,255,128))]
>>
>>Now you're asking if it evaluates to < 10 ?
>>
>>> ENDIF
>>>ENDFOR
>>>
>>>thanks
- Whoever said that women are the weaker sex never tried to wrest the bedclothes off one in the middle of the night
- Worry is the interest you pay, in advance, for a loan that you may never need to take out.