Page 1 of 2

(RPG) Multi-language app

Posted: Sat Apr 06, 2013 12:22 am
by Fabrice Geay
hy,


I would like to create an app multi-languages ​​(eg French / English).
I know I am obliged to make a schema for a language.

Is it possible that the RPG program knows what default language is used by the iPad?

Is the captions for schema are customizable from RPG?

Re: (RPG) Multi-language app

Posted: Sat Apr 06, 2013 12:28 am
by PascalvanDoorn
Hi,

I think you should check the documentation: http://www.longrangemobile.com/docs/LRP ... struct.htm.

This can be returned with the latest version RV11.

Pascal

Re: (RPG) Multi-language app

Posted: Sat Apr 06, 2013 12:39 am
by Fabrice Geay
Thank you Pascal,

I can retreive the language of the current client.

And for me second question have you got an idea.

Re: (RPG) Multi-language app

Posted: Sat Apr 06, 2013 12:42 am
by PascalvanDoorn

Re: (RPG) Multi-language app

Posted: Sat Apr 06, 2013 12:44 am
by Fabrice Geay
I'll try. I'll let you know

Re: (RPG) Multi-language app

Posted: Tue Apr 09, 2013 5:44 pm
by Fabrice Geay
hy,

I have updgrade my LongRange for use the ClientLanguage.
But the value of ClientLanguage is always '001-000-00' even if i change the default language (My iPad had a French Configuration) to English i have always '001-000-00'.

Re: (RPG) Multi-language app

Posted: Tue Apr 09, 2013 6:29 pm
by MarkDuignan
Could you run the shipped RPG demo?

Programming Examples -> Use Case Examples -> Mobile Device Details.

Then take a screen shot and post it to the forum?

Eg: I see this. The language code shows an “en” …..
Capture.PNG
Capture.PNG (73.28 KiB) Viewed 8330 times

This is shipped RPG example program LRNG_DEMO/SOURCEEXAM/EXAM0011.

Re: (RPG) Multi-language app

Posted: Tue Apr 09, 2013 7:55 pm
by Fabrice Geay
Hi marck
if I understand correctly, the variable ClientLanguage found in the SystemInfo can not be read directly to determine the language used on the iPad.

In the EXAM0011, it uses a LRNG_GetSystemValues ​​with CURRENT-DEVICE-SYSTEM-LANGUAGE parameter.

This is what I need.
thank.

Re: (RPG) Multi-language app

Posted: Wed Apr 10, 2013 8:41 am
by MarkDuignan
The SystemINFO documentation is incorrect.

There is no language field in the shipped data structure .........

Code: Select all

     D*-------------------------------------------------------------------------
     D* The SystemINFO data structure                                           
     D*-------------------------------------------------------------------------
     DSystemINFO       DS          4096    Qualified                            
     D DesignMode                     5I00                                      
     D aXesRootPath                 512A                                        
     D LRNGImagesPath               512A   Varying                              
     D LRNGDemoImagesPath...                                                    
     D                              512A   Varying                              
     D DeviceTypeName...                                                        
     D                               10A                                        
     D DeviceSizeCategory...                                                    
     D                               10A                                        
     D DeviceScreenWidth...                                                     
     D                               10I00                                      
     D DeviceScreenHeight...                                                    
     D                               10I00                                      
     D aXesRootURL                  512A                                        
     D ClientGUID                    40A                                        
     D ClientRuntimeVersion...                                                  
     D                               10I00                                      
     D ServerVersion...                                                         
     D                               11A                             


What RPG SystemINFO.xxxxxxxx variable name did you use in your original code?

We will amend the doco.

The reason for this change (which was done at the last minute) is that in theory the language can change while an App is active (eg: Italian and French speakers sharing a warehouse device). Not sure whether you would bother to accommodate this in an application though.

Re: (RPG) Multi-language app

Posted: Wed Apr 10, 2013 5:58 pm
by Fabrice Geay
hi,

Actually, I only use the LRNGImagesPath in my code.