I'm using Core data and region monitoring. The only way to distinguish between monitored regions is with a NSString for identifier. I'd love to use NSManagedObjectID, but I can't get it to work.
What I've tried:
NSURL *objURL = [managedObjectID URIRepresentation];
NSError *err;
NSString *identifier = [NSString stringWithContentsOfURL:myURL
encoding:NSASCIIStringEncoding
error:&err];
the error I get is:
The operation couldn’t be completed. (Cocoa error 256.)
Any ideas of a better way? Or what I'm doing wrong?