简体   繁体   English

安装后将无法编译:Mcv.Mailer版本1.0使用Mvc版本4.0,该版本具有比引用的程序集更高的版本Mvc 3.0

[英]Won't compile after installing: Mcv.Mailer version 1.0 uses Mvc version 4.0, which has higher version than referenced assembly Mvc version 3.0

I installed the nuget package for MvcMailer, found here . 我安装了MvcMailer的nuget包,在此处找到。 Although it didn't (as it says in the tutorial it will) add smtp configuration to web.config, I found the correct smtp configuration here . 尽管它没有(如本教程中所说的那样)将smtp配置添加到web.config,但我在这里找到了正确的smtp配置。

I'm using MVC4 in VS2010. 我在VS2010中使用MVC4。

When I compile, I get the following error in the the error list: 编译时,我在错误列表中得到以下错误:

Error 1 Assembly 'Mvc.Mailer, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' uses 'System.Web.Mvc, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' which has a higher version than referenced assembly 'System.Web.Mvc, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' c:\\Users\\Home\\Desktop\\MVCMusicStore - Copy\\packages\\MvcMailer.4.0\\lib\\40\\Mvc.Mailer.dll MVCMusicStore 错误1程序集'Mvc.Mailer,Version = 1.0.0.0,Culture = neutral,PublicKeyToken = null'使用'System.Web.Mvc,Version = 4.0.0.0,Culture = neutral,PublicKeyToken = 31bf3856ad364e35'具有更高的版本引用的程序集'System.Web.Mvc,版本= 3.0.0.0,文化=中性,PublicKeyToken = 31bf3856ad364e35'c:\\ Users \\ Home \\ Desktop \\ MVCMusicStore-Copy \\ packages \\ MvcMailer.4.0 \\ lib \\ 40 \\ Mvc.Mailer。 dll MVCMusicStore

I also get the following warning: 我还会收到以下警告:

Warning 2 Found conflicts between different versions of the same dependent assembly. 警告2发现相同从属程序集的不同版本之间存在冲突。 MVCMusicStore MVCMusicStore

I removed the MvcMailer reference and added it again, but it didn't resolve the issue. 我删除了MvcMailer参考,并再次添加了它,但是它不能解决问题。

Help would be much appreciated. 帮助将不胜感激。

I'm using Mvc 4, and was installing MvcMailer via the package manager with the following: 我正在使用Mvc 4,并且正在通过软件包管理器安装MvcMailer,并具有以下内容:

install-package MvcMailer

Because I'm using Mvc 4, the following should be used: 由于我使用的是Mvc 4,因此应使用以下内容:

install-package MvcMailer3

This has resolved the issue. 这样就解决了问题。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 程序集&#39;SomeAssembly,使用&#39;System.Web.Mvc,Version = 4.0.0.0,它的版本高于引用的程序集&#39;System.Web.Mvc,Version 3.0.0.0 - Assembly 'SomeAssembly, uses 'System.Web.Mvc, Version=4.0.0.0, which has a higher version than referenced assembly 'System.Web.Mvc, Version 3.0.0.0 程序集使用版本X,其版本高于引用的程序集错误 - Assembly uses version X which has a higher version than referenced assembly error 程序集XXX具有比引用的程序集XXX高的版本 - Assembly XXX which has a higher version than referenced assembly XXX 具有比参考程序集更高版本的程序集“ XXX” - Assembly 'XXX' which has a higher version than referenced assembly <Assembly>使用Microsoft.Synchronization,它具有比引用程序集更高的版本 - <Assembly> uses Microsoft.Synchronization which has a higher version than referenced assembly 程序集 'System.Web.Http, ...' 使用 'Newtonsoft.Json, Version=6.0.0.0...' 其版本高于引用的程序集 - Assembly 'System.Web.Http, ...' uses 'Newtonsoft.Json, Version=6.0.0.0...' which has a higher version than referenced assembly ECS1705,其版本高于引用程序集 - ECS1705 which has a higher version than referenced assembly C# - .net core - 比引用的程序集版本更高的程序集 - C# - .net core - Assembly which has a higher version than referenced assembly Unity 错误 CS1705:其版本高于引用的程序集 - Unity error CS1705: which has a higher version than referenced assembly 我在使用的MVC程序集版本邮政版本高于我项目引用的版本。 我该如何解决? - I get error on build that mvc assembly version postal is using is higher than referenced by my project. How do I resolve this?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM