NetTalk Central

NetTalk Web Server => Web Server - Ask For Help => Topic started by: lkeyser on February 12, 2020, 12:11:02 AM

Title: Please assist with translate question
Post by: lkeyser on February 12, 2020, 12:11:02 AM
I hope i'm not pulling a stunt that can't be done.
I'm adding a small sample app of my problem.

I have to write a multi language webapp..

I can translate all headers in browser and Forms, menus, including some data on a drop list.
But the data in the browse does not translate the data.

In the sample I'm showing that Gender translates 100% in the form as a drop list when your select an alternative language.
but shows as the default Language in the browse.

Please assist me in to correct approach to this problem.
Many Thanks

Title: Re: Please assist with translate question
Post by: Bruce on February 24, 2020, 12:14:28 AM
Hi Leon,

Obviously some data in the database is going to translate, and some is not.
Names, numbers etc are all "language neutral" - whereas things like Gender can be translated.

the key is to set the DISPLAY field for the browse column. (there on the Field tab).
In your case to
p_web.translate(Sma:Gender)
and then obviously add to the WebHandler as well.

As a complete aside, instead of endless IF statements, you may want to use a CASE statement instead.

cheers
Bruce


Title: Re: Please assist with translate question
Post by: lkeyser on February 25, 2020, 03:00:33 AM
Thanks Bruce...

It works ! Thanks for the tip

Regards