"Localization file not found"

Stimulsoft Reports.Flex discussion
Locked
jorool
Posts: 44
Joined: Wed Dec 08, 2010 1:39 pm
Location: Brazil

"Localization file not found"

Post by jorool »

Hello!

At the initialization of my app I add two languages:

Code: Select all

var ptBR:StiLanguage = StiLanguage.fromUrl("localeReport/pt-BR.xml", "",  "Português (Brasil)", "");
var es:StiLanguage = StiLanguage.fromUrl("localeReport/es.xml", "",  "Español", "");
StiLocalization.addLanguage(ptBR);
StiLocalization.addLanguage(es);
StiLocalization.setLanguage(ptBR);
But in the viewer the message "Localization file localeReport/pt-BR.xml not found" is showed.
Can you help me?
What is the problem?

Thanks.

[EDIT]: current version is 2012.1.1207
Vladimir
Posts: 1462
Joined: Fri Apr 13, 2007 4:05 am
Location: Earth

"Localization file not found"

Post by Vladimir »

Hello,

We could not reproduce the error. Please see the attached example.

Thank you.
Attachments
1580.LocalizationSample.zip
(1.52 MiB) Downloaded 537 times
jorool
Posts: 44
Joined: Wed Dec 08, 2010 1:39 pm
Location: Brazil

"Localization file not found"

Post by jorool »

Hello Vladimir,

I could not find diferences between our codes.
Please see the images. I want to show you the folder structure of the project and where the localization files are.
The method registraIdiomasRelatorio() is executed without errors.
Image
Attachments
1610.print.png
1610.print.png (6.26 KiB) Viewed 6559 times
1609.print.png
1609.print.png (129.95 KiB) Viewed 6560 times
Vladimir
Posts: 1462
Joined: Fri Apr 13, 2007 4:05 am
Location: Earth

"Localization file not found"

Post by Vladimir »

Hello,

Please try to specify the following path to the localization files:

"main/flex/localeReport/pt-BR.xml"

Thank you.
jorool
Posts: 44
Joined: Wed Dec 08, 2010 1:39 pm
Location: Brazil

"Localization file not found"

Post by jorool »

Hello Vladimir!

The same error!
Attachments
1612.print.png
1612.print.png (5.39 KiB) Viewed 6546 times
Vladimir
Posts: 1462
Joined: Fri Apr 13, 2007 4:05 am
Location: Earth

"Localization file not found"

Post by Vladimir »

Hello,

Please tell us which folder the compiled application is copied to? In this folder the localization files will automatically be copied, and it is needed to set the path to them relatively to this folder, because the swf file of the application is there.

Thank you.
jorool
Posts: 44
Joined: Wed Dec 08, 2010 1:39 pm
Location: Brazil

"Localization file not found"

Post by jorool »

Hello,

This path was working fine for months.
Can I use "../" to go back through the folders?
Attachments
1613.print.png
1613.print.png (33.53 KiB) Viewed 6539 times
jorool
Posts: 44
Joined: Wed Dec 08, 2010 1:39 pm
Location: Brazil

"Localization file not found"

Post by jorool »

Hello!

I moved the "localeReport" folder to the folder wich the compiled application is to try to solve the problem.....same error.
So I moved it back......and worked... ._. (poker face) ...mistery of midnight.
Its working now.

Thank you for your attention!
Vladimir
Posts: 1462
Joined: Fri Apr 13, 2007 4:05 am
Location: Earth

"Localization file not found"

Post by Vladimir »

Hello,

Most likely the folder with localizations files for some reason do not automatically copy to the resulting folder. In this case, the files can be copied manually, that you did.

Thank you.
Locked