Convert NSString to string
- by coure06
NSDate *now = [NSDate date];
NSDateFormatter *formatter = [[NSDateFormatter alloc] init];
[formatter setDateFormat:@"yyyy"];
NSString *stringFromDate = [formatter stringFromDate:now];
CGContextShowTextAtPoint(context, 50, 50, stringFromDate, 5);
I am not getting the exact date? also getting warning while compiling
warning: passing argument 4 of 'CGContextShowTextAtPoint' from incompatible pointer type