Hi,
I have a grid which will display all the fields' data of mytable. Sample data as the following:
Status Attachcount Subject Body
.F. 1 MS Memo
.T. 0 ME Memo
I would like to show the coresponding picture on the relevant column base on mytable.status, mytable.Attachment.So I plave the following statement in Init of Grid.
#DEFINE Unread c:\aaa\a.bmp
#DEFINE READ c:\aaa\B.bmp
#DEFINE Attach c:\aaa\c.bmp
#DEFINE NonAttach c:\aaa\d.bmp
THIS.column1.SETALL("picture", ;
IIF(Mytable.status= .T.,UnRead,READ), "image")
THIS.column2.SETALL("picture", ;
IIF(Mytable.Attachcount > 0,Attach,NonAttach), "image")
The result shown in the grid are not correct and as the following
Grid
Column1 Column2 ...
pic of Read pic of Attach
pic of read pic of attach
Seens all the conditions in IIF statment are all base on the 1st/current recound. Anyone have any ideas/ experiences to solve this problem?
Thank you
I am not the most powerful man in this world.
I am not the worst man in this world either.
I just as same as all of you.
I still need to learn from my mistakes...