开发者

Deploy ASP.NET app without .resx file?

I have an ASP.NET web application with a .resx file in App_GlobalResources whose resources are typically accessed like this:

ASPX: <asp:Literal ID="l1" runa开发者_StackOverflow中文版t="server" Text="<%$ Resources:GalleryServerPro, Admin_Tab_Hdr %>" />

Code-behind: string msg = Resources.GalleryServerPro.Successfully_Restored_Msg;

Is there any way to compile the .resx values directly into the DLL so that I can deploy the app without the .resx file and not have to edit any of the existing code?

I ask this because I am porting an existing app to a DotNetNuke module and DotNetNuke does not allow .resx files, so I am looking for a workaround.

Thanks, Roger Martin Gallery Server Pro


You do not need to change your code. You need to look at creating satellite assemblies.

This is covered in better detail in blog postings such as: http://blogs.msdn.com/pedram/archive/2007/08/04/automated-build-of-satellite-assemblies-in-visual-studio-with-msbuild.aspx

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜