First, there are numerous ideas in play on how to translate text labels, buttons, etc. Here's my idea.
The FileMaker Button Bar can be used, as well as text objects, for displaying the contents of the variables. Just double click and type in the $$VariableName.
I tried many methods of creating the variables and most of them were a pain in the neck as I was creating new words to use on the fly. Having to edit a 300 variable script is a pain...
So, I decided to use a table for creating and naming the variables. What would be easier than adding a new one to a table with one looping script to fill in the values. Wow. Much easier. But I ran into a problem with naming the variables. Fortunately skywillmott provided the missing value for me where I had not added a one.
After playing with my idea quite a bit and using skywillmott's idea (never thought of adding the 1) I have it working:
- Create or delete $$variables on the fly
- Use a table to create the variables (text field for name, calc field for variable name)
- Create a method for getting the translations from Google translate
- Select language
- Create a variable to paste into Google
- Paste and translate and copy
- Paste results into global and then use that
- Import words into translation table
- Fill variable values with translation
Works fine and almost instantly when switching the default language with 239 $$Variables which update instantly on all of my layouts. Works just fine over Wi-Fi on my local setup.
Here's my first video (I will post in separate thread also)
First part just shows the table for the variable names. You can see the 239. Using this list I can add a new word/variable easily. Then I can send the new words to Google Translate, etc.
Second part shows the idea in action on my iPhone layout. First we choose the language and then we go to the report layout where we can select a report to view. Then I return and change the language again and go to the report view. I need a film editor to smooth this out...volunteers?
I don't know what the limit on the reasonable number of variables but it will depend upon the developer. If it overloads then the number of variables active can be reduced as needed, even creating them when a layout is changed. I currently load the 239 variables on startup and change them almost instantly in the dashboard as you will see in real time.
i have translated all of the languages that FileMaker installs and the idea is capable of handling the 2000 other languages of the world as long as the fit inside the text field and have ascii characters, or something like that. The languages are shown in the scrolling list although I only used two.