Link to home
Start Free TrialLog in
Avatar of jackjohnson44
jackjohnson44

asked on

asp.net resource files, do I need to set a default language?

I need to add resource files to my application.  In most instances there will be only one verions.  I initially used riblet.rexs, but then started seeing errors in the log file that said it was looking for riblet.en-Us.resx.  Do I need to name my file this?  I realize that this is english.

My thought was to use the file with no language extension, then add files with language extensions only when it was necessary, for instance if I needed to add a french version.

In most cases the files will be language neutral and will just hold values that need to be changed without recompiling the code.
ASKER CERTIFIED SOLUTION
Avatar of Jacques Bourgeois (James Burger)
Jacques Bourgeois (James Burger)
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of jackjohnson44
jackjohnson44

ASKER

Thanks.  I know how to deploy.  Everythign works.
If I try to access a file like below, I will get lines in the log file that say it can't find Riblet.en-US.resx.  It will still find the value and everythign works, but the log files fill up.

SPUtility.GetLocalizedString("$Resources:key", "Riblet", (uint)System.Threading.Thread.CurrentThread.CurrentCulture.LCID);

I want to optionally use additional languages only if I need them.  So if I want Riblet.fr.resx I can use it, if not it will default to the Riblet.rexs file.  I can get around the error by using Riblet.en-US.resx, but I don't want to also use Riblet.resx which would be an exact copy.

Again, the function call works, I just don't want the log file filling up.