I\'ve seen in some projects something like:
#if .....
code...
#endif
but i can\'t find it now...
Let\'s say, for example, if the ap
You can get OS version like this:
NSString *version = [[NSProcessInfo processInfo] operatingSystemVersionString];
NSLog(version);
Output:
NSString *version = [[NSProcessInfo processInfo] operatingSystemVersionString];
NSRange range = NSMakeRange(8, 4);
NSString *justVersion = [version substringWithRange: range];
NSLog(@"%@", justVersion);
Result:
And for checking:
if ([justVersion isEqualToString:@"10.7"]) {
code...
}
else {
...
}