C# 在visual studio 2017中将类库参考(framwork 4.6.1)添加到asp.net核心

C# 在visual studio 2017中将类库参考(framwork 4.6.1)添加到asp.net核心,c#,asp.net-core-1.1,C#,Asp.net Core 1.1,我在asp.net core 1.1应用程序中添加了在framework 4.6.1中开发的类库。我可以访问asp.net核心项目中类库的类和其他对象。但当我运行我的项目时,我发现运行时出错了。如果我从代码中删除类和类库的所有引用对象,它就会工作。有解决办法吗 代码: 在重建/生成解决方案之前,请参考类的dll,并确保属性(右侧)中的“复制本地”设置为true。这样,当你构建/重建时,它会将dll复制到你的调试文件夹。不起作用。当它“无法”重建时,你能在这里发布它给出的错误消息吗?我已经编辑了我

我在asp.net core 1.1应用程序中添加了在framework 4.6.1中开发的类库。我可以访问asp.net核心项目中类库的类和其他对象。但当我运行我的项目时,我发现运行时出错了。如果我从代码中删除类和类库的所有引用对象,它就会工作。有解决办法吗

代码:


在重建/生成解决方案之前,请参考类的dll,并确保属性(右侧)中的“复制本地”设置为true。这样,当你构建/重建时,它会将dll复制到你的调试文件夹。不起作用。当它“无法”重建时,你能在这里发布它给出的错误消息吗?我已经编辑了我的问题
  public IActionResult Inquiry([FromBody] MerchantDetailModel details)
            {
                string consumerKey = "-ASDFEEE";
                string keyAlias = "WeirdAlias";
                string keyPassword = "Gooddat";
//This is the class inside the class library
                TerminationMatchInquiry inquiry = new TerminationMatchInquiry(details);

//This where the runtime error comes
                var result = inquiry.RequestCall(consumerKey, keyAlias, keyPassword);
                return new JsonResult("Match");
            }

Error:
System.IO.FileNotFoundException: 'Could not load file or assembly 'MasterCard-Core, Version=1.4.0.26200, Culture=neutral, PublicKeyToken=null'. The system cannot find the file specified.'