星空网 > 软件开发 > ASP.net

未能加载文件或程序集或某一个依赖项

最近看一个开源项目的时候由于自己电脑是32位的,运行项目就报这个错,于是网上找了一下发现这个问题解决方法下面这种最不错的就贴出来或许以后用得上

1.右键卸载项目
2.右键选择编辑工程文件加以下内容:

 1 <PropertyGroup>  2 <ForceResGen32Bit Condition="'$(MSBuildToolsVersion)'=='4.0' And '$(PROCESSOR_ARCHITEW6432)'!='' And '$(TargetingClr2Framework)'=='true' And '$(PlatformTarget)'=='x86'">true</ForceResGen32Bit>  3  4 </PropertyGroup>  5 <Target Name="BeforeResGen" Condition="'$(ForceResGen32Bit)' == 'true'">  6 <PropertyGroup>  7 <ResGenSdkToolsPath>$(IntermediateOutputPath)ResGenForced32Bit\</ResGenSdkToolsPath>  8 </PropertyGroup>  9 <!-- Copy resgen.exe to intermediate working directory for UAC settings --> 10 <Copy SourceFiles="$(TargetFrameworkSDKToolsDirectory)ResGen.exe" 11 DestinationFiles="$(ResGenSdkToolsPath)ResGen.exe" /> 12 13 <!-- corflags.exe resgen.exe /32BIT+ /Force--> 14 <Exec WorkingDirectory="$(ResGenSdkToolsPath)" 15 Command="&quot;$(TargetFrameworkSDKToolsDirectory)corflags.exe&quot; ResGen.exe /32BIT+ /Force" /> 16 17 <!-- GenerateResource Task parameters 18 Using the non-64bit Tracker.exe and indicate resgen.exe has been forced to x86 --> 19 <PropertyGroup> 20 <ResGenTrackerSdkPath>$(SDK40ToolsPath)</ResGenTrackerSdkPath> 21 <ResGenToolArchitecture>Managed32Bit</ResGenToolArchitecture> 22 <CacheTargetFrameworkSDKToolsDirectory>$(TargetFrameworkSDKToolsDirectory)</CacheTargetFrameworkSDKToolsDirectory> 23 <TargetFrameworkSDKToolsDirectory>$(ResGenSdkToolsPath)</TargetFrameworkSDKToolsDirectory> 24 </PropertyGroup> 25 </Target> 26 <Target Name="AfterResGen" Condition="'$(ForceResGen32Bit)' == 'true'"> 27 <PropertyGroup> 28 <TargetFrameworkSDKToolsDirectory>$(CacheTargetFrameworkSDKToolsDirectory)</TargetFrameworkSDKToolsDirectory> 29 </PropertyGroup> 30 31 <RemoveDir Directories="$(ResGenSdkToolsPath)" Condition="Exists('$(ResGenSdkToolsPath)')" /> 32 </Target>

 



3.右键重新加载项目,问题解决。本机实验通过




原标题:未能加载文件或程序集或某一个依赖项

关键词:

*特别声明:以上内容来自于网络收集,著作权属原作者所有,如有侵权,请联系我们: admin#shaoqun.com (#换成@)。

英国资产阶级革命结束的标志是什么:https://www.goluckyvip.com/tag/78325.html
英国的车标:https://www.goluckyvip.com/tag/78329.html
直达爆单:https://www.goluckyvip.com/tag/7833.html
英国资产阶级革命的开始标志:https://www.goluckyvip.com/tag/78330.html
英国陆军军衔标志:https://www.goluckyvip.com/tag/78331.html
英国资产阶级革命开始的标志是:https://www.goluckyvip.com/tag/78333.html
用户体验至上:独立站脱颖而出的关键要素解析:https://www.goluckyvip.com/news/214219.html
用户体验至上:独立站脱颖而出的关键要素解析:https://www.xlkjsw.com/news/88158.html
相关文章
我的浏览记录
最新相关资讯
海外公司注册 | 跨境电商服务平台 | 深圳旅行社 | 东南亚物流