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

AbpWeb Localization extension #6935


User avatar
0
Ricavir created

Hi,

I'm trying to extend "InternalServerError" translation that is in AbpWeb source. I've followed abp documentation : https://aspnetboilerplate.com/Pages/Documents/Localization#extending-localization-sources

I've added following line on LocalizationConfigurer class :

localizationConfiguration.Sources.Extensions.Add(new LocalizationSourceExtensionInfo("AbpWeb", new XmlEmbeddedFileLocalizationDictionaryProvider(Assembly.GetExecutingAssembly(), "Localization.AbpWeb")));

And added XML files on a dedicated folder :

The problem is that "InternalServerError" translation remains always the same after doing that.

Is there another thing to do to make it work ?


2 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team

    Your rootNamespace may be incorrect.

    You can refer to the code of this project.

    It replaces Abp's CurrentUserDidNotLoginToTheApplication as Hello You Need Login!

    https://github.com/maliming/abplocalization/blob/master/src/QA.Core/Localization/QALocalizationConfigurer.cs#L10

  • User Avatar
    0
    Ricavir created

    Tks @maliming. I found the issue, xml files have to be setted as "embedded ressource" instead of none. My bad.