0

I'm developing iPad international application.
I'm using methods NSLocalizableString to translate my application.
I have added keyword manually in my Localizable.strings in English and in French named "Orders" with value.
When I call my method NSLocalizableString with the keyword, it didn't found my keyword and don't apply the translation.
For keyword above and below, it's working perfectly.

Some code parts :

**Localizable.strings**
    /* Change datas */
    "ChangeDatas" =  "Modifier les données";
    /* Orders */
    "Orders" =  "Détails de votre commande";
    /* Label */
    "SomeLabel" =  "Label";
**file.m**
    //Work fine
    NSLog(@"My data translation : %@", NSLocalizedString(@"ChangeDatas", @"Change datas"));
    //Don't work
    NSLog(@"My orders translation : %@", NSLocalizedString(@"Orders", @"Orders"));
Sklivvz
  • 30,601
  • 24
  • 116
  • 172
alexmngn
  • 9,107
  • 19
  • 70
  • 130
  • Did you try to clean and re-build your app? Also uninstall old version before reinstalling it. I noticed that iPhone tends to cache the localization data somewhere and clean/reinstall might be necessary that it would note the changes. – MrTJ Apr 04 '12 at 10:03
  • I've tried to do that but not success. – alexmngn Apr 04 '12 at 10:07
  • Everything looks fine. Try to control whether you do not have some strange whitespace in your string or if your characters are in the right encoding. Remove and add another string. – MrTJ Apr 04 '12 at 10:27

1 Answers1

0

Are you sure your editor was working in the right encoding? Also, with the correct line endings?

It can't hurt to check your .strings file with the plutil command.

Are you sure you've edited the .strings file for the same language/locale that you're using at runtime?

Ken Thomases
  • 88,520
  • 7
  • 116
  • 154
  • The encoding are UTF16 and the line ending are LR (unix). I've tried to user the plutil command and it return OK. I've tried to edit the 2 files( EN & FR ) and nothing change. – alexmngn Apr 04 '12 at 12:05