我想,以使资源文件是部署后编辑。我读this后这表明这是可能的,但我似乎无法找出什么设置,我需要改变,以使这一点。
I'd like to enable the resource files to be editable after deployment. I read this post which suggests that this is possible, but I can't seem to figure out what settings I need to change to enable this.
我已经加入了文件夹App_GlobalResources文件到我的ASP.NET 3.5Web应用程序,并增加了一个资源文件到这个文件夹。我认为需要更改该文件的生成操作,但无论怎样我生成操作改变,我无法实现上述功能。
I have added the App_GlobalResources folder to my ASP.NET 3.5 "Web Application" and added a resource file to this folder. I assume that the Build Action for this file needs to be changed, but no matter what I change the Build Action to, I cannot achieve the above stated functionality.
在App_GlobalResources文件夹和资源文件复制到bin目录中。一旦部署,不被显示给.resx文件的任何修改。
The App_GlobalResources folder and the resource file are copied into the bin directory. Once deployed, any edits to the .resx file are not being displayed.
任何想法?
推荐答案一个Web应用程序项目比一个网站项目不同。我怀疑你可以达到你想要一个Web应用程序项目什么。你可以看看这篇文章:
A Web Application project is different than a Web Site project. I doubt you can achieve what you want with a Web Application project. You might check out this post:
stackoverflow/questions/398037/asp-net-web-site-or-web-application
资源通常意味着是静态的。它们是项目,如图像,字符串和文件程序消耗,并且可以依靠为present,(因此可以在串/ RESX文件的情况下进行强类型)。之所以使用的资源是简单地捆绑它们与你的DLL,使分布和引用的资源变得更加容易。
Resources are generally meant to be static. They are items such as images, strings, and files that your program consumes and can rely on being present, (and therefore can be strongly typed in the case of strings/RESX files). The reason for using resources is simply to bundle them in with your DLL's so that distribution and referencing the resources becomes much easier.
在运行时可编辑建议您可能要使用的项目或用户设置,或者一个数据库?如果您需要使用RESX文件可能需要编写code读/写。
Editable at runtime suggests you might want to use project or user Settings, or maybe a database? If you need to use RESX files you might need to write code to read/write them.
更多推荐
无需重新编译ASP.NET应用程序中编辑资源文件
发布评论