Also, I’m doing a Localization webinar on December 10th: https://www.xojo.com/support/webinar.php

Again thanks to everyone. I guess in my mind the idea of “detecting” the OS language got too complicated. And special thanks to Thomas, Norman, and Paul for your input. I just enrolled for the seminar next Tuesday. Though I will be out of town, I should still be able to catch it. And Thomas I was aware of Lingua, which I had read about in BKeeney Briefs. Thank you.

Some apps I did kept their strings in a local table and controlled by a global property. I often ran out of available space because (I’m Dutch) translated strings in French and German take often more space (there is a specific ratio like French strings are 1.4 times Dutch strings) so I had to abbreviate which looks ugly and resulted in a poorly understood interface. Keep that in mind.

@Paul Lefebvre Watched your Webinar and read as much of the documentation as I can find on Localisation, but struggling to find way to localize strings from a database. Any ideas? Currently everything is just saved as English, but I’d like to swap that text out with references to constants and be able to run some sort of parse command on a string from the database to parse out any constants at runtime with the local language.

If you want to dynamically change the text using strings from the database, you’ll have to do that manually yourself. Xojo’s built-in localization support uses the OS features to swap out the text when the app starts.

This blog post might also be helpful:

@Paul Lefebvre Thank you Paul, really appreciate your answer, that’s what I had assumed.

For anyone looking at my question in future, I’ve ended up building a parse function using Introspection to find constants within a class, find any occurrence of their name within the supplied string and replace it with the constant value (found by using invoke).