How to access resources from an external assembly
I want to create a vb.开发者_JAVA百科net project that I will use to only hold image and string resources that I will need in multiple projects.
What I can't figure out is how do I access these resources using code from other projects.
You'll need to load the assembly by either referencing it in your projects or calling Assembly.Load to load the actual DLL files and create a new object called ResourceManager passing along the assembly you loaded or the type of the assembly (if you referenced it in your project).
Then make calls from the Resource manager (GetString, GetInt, GetImage, etc) for the different things the satellite assembly holds.
精彩评论