【问题标题】:ResourceManager set wrong on saveResourceManager 在保存时设置错误
【发布时间】:2016-10-01 08:38:57
【问题描述】:

我遇到一个问题,每次我更改我的资源文件时,ResourceManager 设置的路径无效。

例子

namespace bundlrs_MVC6.Resources {
...    
global::System.Resources.ResourceManager temp = new global::System.ResourceManager("bundlrs_MVC6.HomeIndexViewResources", typeof(HomeIndexViewResources).GetTypeInfo().Assembly);

应该是:(注意额外的资源)

namespace bundlrs_MVC6.Resources {
...  
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("bundlrs_MVC6.Resources.HomeIndexViewResources", typeof(HomeIndexViewResources).GetTypeInfo().Assembly);

文件夹结构:

我正在使用 Visual Studio 2015

我是否应该将所有资源文件移动到:namespace bundlrs_MVC6 而不是namespace bundlrs_MVC6.Resources 如果是,为什么?

【问题讨论】:

    标签: c# asp.net-mvc visual-studio asp.net-core


    【解决方案1】:

    CoreCLR 1.0.0 RTM 版本已修复此问题

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-11-20
      • 1970-01-01
      • 1970-01-01
      • 2017-02-28
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多