Hi,
I am trying to get the value of a cellTag in CellBackGroundPaint. However when it gets to
Dim TrackID as string = me.CellTag(row,1)
It calls the function again and we get into a loop. Can someone please tell me what i am doing wrong here? Thanks
Here is my CellBackGroundPaint function
[code] if row mod 2=0 then
if me.ListIndex<>row then
g.ForeColor=&cECF3FE
g.FillRect 0,0,g.Width,g.Height
end if
end if
Dim TrackID as string = me.CellTag(row,1)
Dim haveTrack as Boolean = false
Dim ImageFile As FolderItem
Dim PlusSign As Picture
Dim x, y As Integer
dim i as integer
'Listened too
If column =1 Then
i = 1
while i < app.ListenTo.count
dim s as string = app.ListenTo.Item(i).StringValue
if s = TrackID then
haveTrack = true
Exit While
end if
i = i+1
Wend
if haveTrack then
ImageFile = GetFolderItem(app.FilesPath).child("Images").child("listened.png")
If ImageFile <> Nil And ImageFile.Exists Then
PlusSign = Picture.Open(ImageFile)
If PlusSign <> nil Then
g.DrawPicture PlusSign, 2,2
Return True
End If
End If
end if
End If[/code]