(Newbie alert)
I'm having trouble initializing a constant static string in objective-C:
Basically what I want to do is create a constant string from a NSLocalizedStringWithDefaultValue(...)
Any ideas?
(Newbie alert)
I'm having trouble initializing a constant static string in objective-C:
Basically what I want to do is create a constant string from a NSLocalizedStringWithDefaultValue(...)
Any ideas?
Declare a static string in one of your implementation files. In either the class's initialize
method or another appropriate setup point (depending on the exact circumstances — the sharedInstance
method would be a good place in a singleton, for example), assign the localized string to the variable.