Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Run-Time Translation

Status
Not open for further replies.

Karl72

Programmer
Jun 28, 2011
2
DE
Greetings Everyone,
I need help with Clarion's Run-time Translation feature. My program is written with english text on the buttons, menus, list-boxes etc.
I need to enable users to switch to German. I have not been able to figure out how this Run-Time translation works in Clarion.
Can anybody explain what one should do or post a simple example. I'm using Clarion 8.

Thanks,
Karl
 
Hi Karl,

I do not use translation in my applications, but the help would be first place to start. As you can see from the help below, it is fairly simple. I am not sure if there are templates for translation but there are 3rd party products like BoTran ( which would make it easier.

Code:
MyTranslations GROUP                    !declare local translations

Pairs          USHORT(4)               !4 translations pairs
               PSTRING('&Sound')       ! item 1 text
               PSTRING('&xSoundx')     ! item 1 replacement text
               PSTRING('&Volume')      ! item 2 text
               PSTRING('&xVolumex')    ! item 2 replacement text
               PSTRING('Preferences')  ! item 3 text
               PSTRING('xPreferencesx')! item 3 replacement text
               PSTRING('OK')           ! item 4 text
               PSTRING('xOKx')         ! item 4 replacement text
             END

Translator           TranslatorClass    !declare Translator object

CODE

Translator.Init                        !initialize Translator object
                                       !add default translation pairs

Translator.AddTranslation(MyTranslations) !add local translation pairs

OPEN(MyWindow)

Translator.TranslateWindow                !translate all window controls
                                          ! and window titlebar

Regards
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top