In a former post, I provided a simple technique to allow FileMaker Developers to put multilingual labels on their layouts. That tackles the majority of the multilingual requirements for the average system. In some cases however, we need a little bit more multilingual integration in our systems. This module will provide you with a means to create and edit multilingual valuelists in your solution.
Integrating this module into your existing solution should be relatively simple.
You will need to:
- Copy/Import tables from this module into your solution (no need to copy the “~Contacts” table as it’s just a sample
- Recreate the relationships in your solution (see sample image)
- Copy the “Edit Value Lists” layout into your solution (It’s based on “Defaults” )
- Attach “Get List Of VL Tables” script to the OnLayoutEnter script trigger for that new layout
- Run the “Get List Of VL Tables” script
Creating New Value Lists
This will also be extremely easy. You will need to:
- Duplicate one of the existing “VL_” tables (new table name must begin with “VL_” and field names must remain the same)
- Ensure that a new layout got created when you created that table (it doesn’t have to show up in the menu, but it must have a name that matches the table name)
- Create a relationship to the new TO (starting from “Defaults” relate it to your table with a cartesian product)
- Create a value list (I recommend duplicating one of the existing value lists, and just repointing the zc__recordSerial and userValue fields to the same fields in your new table)
The values in the value lists that you use throughout your system will be dependant on the value chosen in the global field in the “Defaults” table.
If the value is 1, then it will use the first column of values (the first language), 2 will represent the 2nd column of values… and so on.
This system is currently set up using 5 repetitions, and this allows it to support up to 5 languages. If you need more languages, simply increase the number of repetitions on all the repeating fields, and make sure that those new repetitions also show up on your layouts.
This technique relies heavily on the usage of Virtual List tables, and uses “Get ( RecordID )” instead of an actual serial number within the tables. This makes it easier to setup and use, but because it’s set up like this, I want to make sure that you do not provide any interface for your users to delete records from your “VL_” tables. You could provide buttons that would make them think they’re deleting records from that table, and really just clear the values from the record instead if your users require that kind of functionality