I have a typical problem: I am not able to internationalize my project. I just want to add support for the english and german language. I've followed thw instructions from this tutorial: http://www.iphonesdkarticles.com/2008/11/localizing-iphone-apps.html
I have in my Project a en.lproj folder, which has Localizable.strings which has a English file with following key: "WelcomeKey" = "Welcome!!!";
But in my program, after implementing the code below, instead of showing the internationalized String "Welcome!!!" the program shows its Key "WelcomeKey". Why is that happening?
My code:
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
NSArray *languages = [defaults objectForKey:@"AppleLanguages"];
NSString *currentLanguage = [languages objectAtIndex:0];
NSLog(@"Current Locale: %@", [[NSLocale currentLocale] localeIdentifier]);
NSLog(@"Current language: %@", currentLanguage);
NSLog(@"Welcome Text: %@", NSLocalizedString(@"WelcomeKey", @""));
My project folder: