Loading images in an NSImageCell in a table view

Hi, i am currently populating a table view containing three columns, one for a file name, and two containing icons respresenting different status for the file. Here’s a part of my code where I actually create the row and populate it. The problem is that I can run it like 10 times with no errors and sometimes without changing anything (just quit & relaunch) I get this error and the table stops populating:

2005-08-04 15:37:58.834 some application[2551] NSImageCell’s object value must be an NSImage.


set backupItem to make new data row at the end of the data rows of theDataSource
set contents of data cell "backups" of backupItem to theFileName
set contents of data cell "local" of backupItem to load image "Home Small"
if isRemote then
	set contents of data cell "remote" of backupItem to load image "Network Small"
else
	set contents of data cell "remote" of backupItem to load image "Network Small Shaded"
end if

I have also tried by first loading images into a variable an then assigning them directly to the content of the data cell but same thing… work 5 to 10 times… gives an error… works 2-3 times… gives an error…

It is very intermitent and I was not able to identify the cause of the problem because of that.