The compiler automatically adds the default namespace and folder location to
the resource file, so when you add the resource to the ResourceManager
object, you should use the whole name.
For example, I have a project called "MyProject", whose default namespace is
"MyProject.Core". I added a "Localization.resx", the structure is:
Core <project name... default namespace = "MyProject.Core">
|- References
|- Other Project folders
|-Resources
| \- Localization
| \- Localization.resx
|
\Localization.cs
The route I have to give the ResourceManager when opening is:
"MyProject.Core.Resources.Localization.Localizatio n"
Something like:
using System.Threading;
using System.Resources;
<add class definition here>
public static ResourceManager m_ResMan;
m_ResMan = new
ResourceManager("MyProject.Core.Resources.Localiza tion.Localization",Assembl
y.GetExecutingAssembly());
Otherwise, if you want to know the exact name, look in the "obj/" folder
after compiling, there should a ".resources" file with the complete name
given by the compiler to that resource, in my case:
MyProject.Core.Resources.Localization.Localization .resources
Hope this helps,
Javier Campos
Virtual Media Systems, S.L.
"KMILO" <km*****@hotmail.com> escribió en el mensaje
news:OM**************@tk2msftngp13.phx.gbl...
Hello,
Thanks ins advance for reading my message
Im trying to use many .resx files for different webforms when I try to the
project the following error appears:
Could not find any resources appropriate for the specified culture (or the
neutral culture) in the given assembly. Make sure "Site.resources" was
correctly embedded or linked into assembly "Site". baseName: Site
locationInfo: <null> resource file name: Site.resources assembly: Site,
Version=1.0.1384.18527, Culture=neutral, PublicKeyToken=null
Anyone knows what could be happend, thanks for your help!!!
Thankfully,
KMILO