Dump your created keys. The answer should be in them.
Ramsey
On Aug 3, 2012, at 7:11 AM, WebObjects TORAcom wrote:
> Hi Ramsey thanks for the answer.
>
> I tried it with no luck.
>
> This is my configuration on EOModeler:
>
> <Screen Shot 2012-08-03 at 09.02.22.png>
>
> Entity name: Usuario
> Attribute name: usuario
>
>
> ../Resources/Spanish_MX.lproj/Localizable.strings contents
>
> {
> "PropertyKey.usuario" = "Login ID";
> "Usuario.usuario" = "Login ID";
> "components.general.Main.username" = "Usuario";
> "components.general.Main.password" = "Contraseña";
> "components.general.Main.message" = "Use un nombre de usuario y contraseñaa
> válidos para acceder al sistema.";
> "components.general.Main.loginMessage" = "Iniciar sesión en el Sistema";
> "components.general.Main.administrator" = "Administrador";
> "components.general.Main.confirmPassword" = "Confirmación";
> "components.general.Main.name" = "Nombre completo";
> "components.general.Main.usernameRules" = "Mínimo 5 y Máximo 15 caracteres";
> "components.general.Main.passwordRules" = "Mínimo 6 y Máximo 15 caracteres";
> "components.general.Main.next" = "Continuar";
> }
>
> ../Resources/Spanish_MX.lproj/ValidationTemplate.strings contents
> {
> "NullPropertyException" = "Favor de proporcionar
> @@displayNameForProperty@@.";
> }
>
>
> ../Resources/English_US.lproj/Localizable.strings contents
>
> {
> "PropertyKey.usuario" = "Login ID";
> "Usuario.usuario" = "Login ID";
> "components.general.Main.username" = "Username";
> "components.general.Main.password" = "Password";
> "components.general.Main.message" = "Use a valid username and password to
> access.";
> "components.general.Main.loginMessage" = "System Login";
> "components.general.Main.administrator" = "Administrator";
> "components.general.Main.confirmPassword" = "Confirm Password";
> "components.general.Main.name" = "Name";
> "components.general.Main.usernameRules" = "Min. 5 Max. 15 characteres";
> "components.general.Main.passwordRules" = "Min. 6 Max. 15 characteres";
> "components.general.Main.next" = "Next";
> }
>
>
> ../Resources/English_US.lproj/ValidationTemplate.strings contents
> {
> "NullPropertyException" = "Please provide @@displayNameForProperty@@.";
> }
>
> All files are UTF-16 enconded and everything works great except for the
> validation message
>
> But I am still getting the same validation message:
>
> <Screen Shot 2012-08-03 at 09.10.57.png>
>
> <Screen Shot 2012-08-03 at 09.10.24.png>
>
> Am I doing something wrong?
>
> Migue Torres
>
> On 02/08/2012, at 19:29, Ramsey Gurley <[email protected]> wrote:
>
>> Try
>>
>> PropertyKey.usuario
>>
>> and
>>
>> Usuario.usuario
>>
>> D2W uses one, the validation system uses the other. Yes, that's confusing :-)
>>
>> Ramsey
>>
>>
>> On Aug 2, 2012, at 4:53 PM, WebObjects TORAcom wrote:
>>
>>> Thanks for your help.
>>>
>>> Now I am testing the localization of Validations
>>>
>>> In my ValidationTemplate.string I have this for Spanish_MX:
>>>
>>> {
>>> "NullPropertyException" = "Favor de proporcionar
>>> @@displayNameForProperty@@.";
>>> }
>>>
>>> and for English_US:
>>>
>>> {
>>> "NullPropertyException" = "Please provide a
>>> @@displayNameForProperty@@.";
>>> }
>>>
>>>
>>>
>>>
>>> I want to change the displayNameForProperty depending on the language.
>>>
>>> The entity's name I am testing is "Usuario" and the attributes name
>>> "usuario"
>>>
>>> I am declaring this in my Localizable.strings file:
>>>
>>> "PropertyKey.usuario" = "Login ID";
>>>
>>>
>>> But I always get
>>>
>>> "Favor de proporcionar Usuario"
>>>
>>> Or
>>>
>>> "Please provide a Usuario"
>>>
>>>
>>> I think did that based on some e-mails I found searching in google,
>>> obviously I am doing something wrong.
>>>
>>> Thanks in advance.
>>>
>>> Miguel Torres
>>>
>>> On 02/08/2012, at 17:30, Amedeo Mantica <[email protected]> wrote:
>>>
>>>> You could put all languages you want in the array the "key" is the order
>>>>
>>>> Sent from my iPhone
>>>>
>>>> On 03/ago/2012, at 00:20, WebObjects TORAcom <[email protected]> wrote:
>>>>
>>>>> Thanks
>>>>>
>>>>> This did the trick
>>>>>
>>>>> public Session() {
>>>>> NSArray<String> langs = new NSArray<String>("Spanish_MX");
>>>>> setLanguages(langs);
>>>>>
>>>>> }
>>>>>
>>>>>
>>>>> On 02/08/2012, at 17:07, Ramsey Gurley <[email protected]> wrote:
>>>>>
>>>>>> If you want to default your localizer to spanish in all your sessions
>>>>>> instead of using the value set by the browser, then in your ERXSession
>>>>>> subclass constructor try adding:
>>>>>>
>>>>>> _localizer = ERXLocalizer.localizerForLanguage("Spanish")
>>>>>>
>>>>>> That should probably work.
>>>>>>
>>>>>> Ramsey
>>>>>>
>>>>>> On Aug 2, 2012, at 1:55 PM, WebObjects TORAcom wrote:
>>>>>>
>>>>>>> Oh, Thanks.
>>>>>>>
>>>>>>> That makes sense, I have configured my browsers to use English as main
>>>>>>> language.
>>>>>>>
>>>>>>> ¿Is there a way to change this behavior? Just to know.
>>>>>>>
>>>>>>> Miguel Torres.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On 02/08/2012, at 14:00, Ramsey Gurley <[email protected]> wrote:
>>>>>>>
>>>>>>>> I may be mistaken, but I believe it respects whatever default is set
>>>>>>>> on the browser for each session.
>>>>>>>>
>>>>>>>> Ramsey
>>>>>>>>
>>>>>>>> On Aug 2, 2012, at 11:56 AM, WebObjects TORAcom wrote:
>>>>>>>>
>>>>>>>>> Hi list,
>>>>>>>>>
>>>>>>>>> I am testing ERXLocalizer, it seems very good.
>>>>>>>>>
>>>>>>>>> I want Spanish as the default language for my app, so I set the
>>>>>>>>> Properties file like this:
>>>>>>>>>
>>>>>>>>> er.extensions.ERXLocalizer.defaultLanguage=Spanish
>>>>>>>>> er.extensions.ERXLocalizer.fileNamesToWatch=("Localizable.strings","ValidationTemplate.strings")
>>>>>>>>> er.extensions.ERXLocalizer.availableLanguages=(Spanish, English)
>>>>>>>>> er.extensions.ERXLocalizer.frameworkSearchPath=(app,ERDirectToWeb,ERExtensions)
>>>>>>>>>
>>>>>>>>> I also have the Spanish.lproj and English.lproj folders inside
>>>>>>>>> Resources directory and a Localizable.strings inside each one.
>>>>>>>>>
>>>>>>>>> This is the content of the English.lproj/Localizable.strings file:
>>>>>>>>>
>>>>>>>>> {
>>>>>>>>> "login_username" = "Username";
>>>>>>>>> "login_password" = "Password";
>>>>>>>>> }
>>>>>>>>>
>>>>>>>>> This is the content of the Spanish.lproj/Localizable.strings file:
>>>>>>>>>
>>>>>>>>> {
>>>>>>>>> "login_username" = "Usuario";
>>>>>>>>> "login_password" = "Contraseña";
>>>>>>>>> }
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> I am testing with one wostring configured like this:
>>>>>>>>> wostrUserNameLabel : WOString {
>>>>>>>>> value = session.localizer.login_username;
>>>>>>>>> }
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> I think every thing is well configured but when I run the App always
>>>>>>>>> shows the english label.
>>>>>>>>>
>>>>>>>>> Am I missing something?
>>>>>>>>>
>>>>>>>>> Thanks in advance.
>>>>>>>>>
>>>>>>>>> Miguel Torres.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> _______________________________________________
>>>>>>>>> Do not post admin requests to the list. They will be ignored.
>>>>>>>>> Webobjects-dev mailing list ([email protected])
>>>>>>>>> Help/Unsubscribe/Update your Subscription:
>>>>>>>>> https://lists.apple.com/mailman/options/webobjects-dev/rgurley%40smarthealth.com
>>>>>>>>>
>>>>>>>>> This email sent to [email protected]
>>>>>>>>
>>>>>>>
>>>>>>> _______________________________________________
>>>>>>> Do not post admin requests to the list. They will be ignored.
>>>>>>> Webobjects-dev mailing list ([email protected])
>>>>>>> Help/Unsubscribe/Update your Subscription:
>>>>>>> https://lists.apple.com/mailman/options/webobjects-dev/rgurley%40smarthealth.com
>>>>>>>
>>>>>>> This email sent to [email protected]
>>>>>>
>>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> Do not post admin requests to the list. They will be ignored.
>>>>> Webobjects-dev mailing list ([email protected])
>>>>> Help/Unsubscribe/Update your Subscription:
>>>>> https://lists.apple.com/mailman/options/webobjects-dev/amedeomantica%40me.com
>>>>>
>>>>> This email sent to [email protected]
>>>
>>> _______________________________________________
>>> Do not post admin requests to the list. They will be ignored.
>>> Webobjects-dev mailing list ([email protected])
>>> Help/Unsubscribe/Update your Subscription:
>>> https://lists.apple.com/mailman/options/webobjects-dev/rgurley%40smarthealth.com
>>>
>>> This email sent to [email protected]
>>
>
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Webobjects-dev mailing list ([email protected])
> Help/Unsubscribe/Update your Subscription:
> https://lists.apple.com/mailman/options/webobjects-dev/ramseygurley%40gmail.com
>
> This email sent to [email protected]
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com
This email sent to [email protected]