I have called NSLocalizedString in my custom keyboard code as follows, but they didn't read the appropriate Localized.string
and I'm always having trouble with English.
data.append(NSLocalizedString("Notes", comment:"Event notes"))
It does not read the .string file in English, it simply appears to display the string of the NSLocalizedString
argument ("Notes"
as mentioned above).
We have added Base
, English
, and Japanese
to Localized.string.
In addition, primaryLanguage
in info.plist is set to mul
, and the simulator and actual device languages are set to Japanese, and the region is set to Japanese.
Could you please advise me where I should check further?
Thank you for your cooperation.
Self-solving.
You named it Localized.string, but if you don't name it Localizable.string, NSLocalizedString will have to specify a filename every time.
© 2024 OneMinuteCode. All rights reserved.