How do I remove content from CALayer?

I have CALayer

with some image content. When the button was touched, I want to remove the content from the layer and I use this code:

[m_aCellLayer setContents:nil]

      

but I am getting an exception EXC_BAD_ACCESS

when I execute the above line. Do you know, why?

0


source to share


1 answer


Just the obvious stuff: is m_aCellLayer valid when you make this call, or has it been released? Have you tried NSLog () just before making a call?



+1


source







All Articles