How to create a resource file (.resx) programatically based on data from an access database
Posted on 2004-04-22
I am trying to make an existing program internationalized, so that you can change language on the fly. This no problem, it's just that I have all keys/values in an access database. The db only contains one table, which has 4 columns: key, english, norwegian, spanish.
This contains about 500 rows. The problem is I don't want to copy all 500 key/english values into a resource file using the .net editor (and repeat it again for all other languages). Because 3 resource files need to be created (nb-NO.resx, en-UK.resx and es-ES.resx). Is there a way to create a little program that reads the database, and then puts all keys and values for english into the en-UK.resx file, then all keys and values for norwegian and put those into nb-NO.resx etc. ????
I can create the resource files beforehand (empty), so I don't have to create the resource files in the code. All it needs to do is add a key and value to the given resourcefile. I have looked in a resource file with no entries, and there was a lot of structure in it. A lot of xml and xsd entries (it looked a bit to complicated for me...). Anyone who has any ideas????