Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

MacDonaldsd

macrumors 65816
Original poster
Sep 8, 2005
1,005
0
London , UK
Hi all,

Im sure I have seen an example of how to do this before but I can't find it now. Basically I am using CoreData and bindings to populate a NSTableView and I would like to have a column that display icons for each file. I currently store the URL to the file so is there a way of doing this with bindings ?

Thanks again
 

kainjow

Moderator emeritus
Jun 15, 2000
7,958
7
I think NSValueTransformer is your friend here. I think you need to bind your image column to your URL (which I'm assuming is in CoreData) and then assign it a custom NSValueTransformer that takes the URL and returns an image from it (NSWorkspace). Check out the NSValueTransformer docs and sample code.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.