开发者

How to use Global Resources in a Library

开发者 https://www.devze.com 2023-01-11 19:46 出处:网络
I use the Global Resources feature, not only to centralize all my output strings but to make it easy when using Localization (witch is almost 90% of the time).

I use the Global Resources feature, not only to centralize all my output strings but to make it easy when using Localization (witch is almost 90% of the time).

But I spread out my project into, not only the ASP.NET website, but with 2 Library projects as well.

my question is:

How can I use the ASP.NET Global Resource file in those Library projects?

as If I do

Resources.MyFilename.MyRe开发者_Go百科sourceStringName

the Library as no knowledge of the MyFilename class

alt text http://www.balexandre.com/temp/2010-08-12_1307.png

What should I do in this cases?


Your going to have to use the ResourceManager class to accomplish this.

MSDN Resource Manager

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号