I am currently porting a project to MacOS, and in the Windows version we use, which is WinAPi Part of the file version information for the window title to determine something.
Is there a similar function on MacOS?
Yes, it's built in the bundle of the app:
NSBindal * Main Bundle = [NSBindal Main Bundle]; NSString * version = [Main bundle object ForForInfoDictionaryKey: @ "CFBundleShortVersionString"]; NSString * build = [Main Bundle Object ForForInfoDictionaryKey: @ "CFBundleVersion"];
.
Comments
Post a Comment