Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

resource strings management across languages #4864


User avatar
0
vladsd created

I noticed that some resources are missing translations. I found one tool which might help with it: <a class="postlink" href="https://github.com/tom-englert/ResXResourceManager">https://github.com/tom-englert/ResXResourceManager</a>

Anyone has a better, favorite recommendation for a tool, process to manage resources and translations?

Thanks.


7 Answer(s)
  • User Avatar
    0
    alper created
    Support Team

    The default way storing in XML files. Are you using Resource Files for translations.

  • User Avatar
    0
    vladsd created

    Thanks. I know xml files and one can edit them one by one. I was hoping for better and integrated tool in VS to help to manage.

  • User Avatar
    0
    vladsd created

    Is there a reason why use XML files and not resx files to store resource strings. The tool I referenced before only supports resx files. It would be nice to be able to do proper string resource management in Visual Studio. Please advise.

  • User Avatar
    0
    aaron created
    Support Team

    From the documentation on Localization:

    Best Practices

    XML files, JSON files and Resource files have their own strengths and weaknesses. We suggest you use XML or JSON files instead of Resource files, because:

    • XML/JSON files are easy to edit, extend or port.
    • XML/JSON files require string keys while getting localized texts instead of compile-time properties like Resource files. This can be considered as a weakness. However, it's easier to change the source later. We can even move the localization to a database without changing the code which uses localization (Module Zero implements it to create a database-based and per-tenant localization source. See documentation on Language Management.)

    If you use XML or JSON, we recommend you do not sort the texts by name. Sort them by creation date! This way, when someone translates it to another language, he/she can easily see which texts have been added recently.

    From the documentation on Language Management:

    MultiTenantLocalizationSource wraps existing DictionaryBasedLocalizationSource-based sources. We generally wrap XML-based localization sources. It cannot wrap Resource File sources since resource files are designed as hard-coded and static files which are not proper for dynamic localization.

  • User Avatar
    0
    vladsd created

    @aaron, if I find the tool to manage it translations and missing strings, I will share

  • User Avatar
    0
    aaron created
    Support Team

    Sure :)

  • User Avatar
    0
    vladsd created

    After research I found a better solution to use ResourceFileLocalizationSource provided by apb

    but it has bugs and does not work, see <a class="postlink" href="https://github.com/aspnetzero/aspnet-zero-core/issues/952">https://github.com/aspnetzero/aspnet-ze ... issues/952</a>