I have a Class Library project that is used by many other web applications. I want to create a satellite assemblies for that class library. I don't want to have to recompile / redeploy the class library when I change one of the resource strings.
While I think I understand the concept of satellite assembly, I don't understand how to build it so that I can use it the way I want.
By default, when you add a resource file to 开发者_高级运维a project in Visual Studio, it sets its build action to "Embedded Resource".
So, my project is called MyProject
. I have a default resource file called MyProject.Resources.resx
and another one called MyProject.Resources.fr.resx
.
When I build, all I get is MyProject.dll
and a "fr" subfolder with MyProject.resources.dll
.
So the way I understand it is that the main assembly (MyProject.dll) contains the default resources because it is set as embedded resource. However, I can't update the resources without redeploying the whole assembly which isn't good for me.
I read on MSDN about packaging assemblies using AL.exe but I still don't understand :
How do I set visual studio so that it outputs my resource files as separate files from the main assembly? From what I read on MSDN, I need .resource files but i'm not quite sure.
Once I do get it the way I want, what would I do if I wanted to modify a resource file? I suppose I would update the resource in visual studio, build the project and copy only the resource DLLs on the target server, is that correct? Would I be able to copy them directly in the GAC along with MyProject.dll
and everything would still work fine?
Thanks!
精彩评论