so there is a solution for this, that handles backward compatibility from ios 5.1 here
My problem is...it does not seem to work, at this point
if (![UIImage conformsToProtocol:@protocol(NSCoding)])
{
}
It skips right over this on my iphone 3gs which is on 4.3 Which would suggest it conforms to protocl NSCoding and then the compiler has a go at me saying there is an exception as uiimage does not respond to encodeObject? so now what i have resorted to is this
@try
{
[encoder encodeObject:_imageToSend forKey:kImageToSend];
}
@catch (NSException *exception)
{
NSLog(@"EXCEPTION @ PhotoImage : %@",exception);
}
@finally
{
[_imageToSend encodeWithCoderForArchiver:encoder];
}
I suspect i am not supposed to excplicitly call encodeWithCoderForArchiver but either way the category this woman has put down is malfunctioning OR more likely i am using it wrong.
Any suggestions?