ios - NSLocalizedString() picking up cached entry from before Localizable.strings is localized -
i building first ios iphone 6 app.
i having problem getting xcode pick key/value pairs localized version of localizable.strings. nslocalizedstring() method seems returning cache entries before localized localizable.strings file.
- you can see in screenshot below when had 1 localizable.strings file, code picks key/value pair looking fine https://www.evernote.com/l/aaii1y9qyi5h9o_siuduteczjzmvyr5fcfw
- when tried localizing localizable.strings file (i.e. having base, english, chinese version of file), nslocalizedstring() returns key value when had 1 localizable.strings file. https://www.evernote.com/l/aalbxeqwnuvfhahmlduagzw5n1op8o2alc8 know happening because when change values same key across 3 files, it's still returning old value.
i've tried
- resetting simulator settings (this suggests cache in build)
- restarting simulator/xcode
- searching old value in project, couldn't find old values nslocalizedstring returning
- changing key else altogether, nslocalizedstring returns key in case
- recreating localizable.strings file , localizing again using file inspector, same thing happens consistently each time
i running out of ideas. using xcode: version 6.3.1 (6d1002), appreciated :)
turned out had clean build. go product -> clean in xcode.
Comments
Post a Comment