问题
I need to reference a dll
which calls an old web service (not svc, but the older one). I'm not quite sure how to go about doing that. I'm using the RC1
version. I could call the web service directly but I'm not sure how to do that either in MVC6.
If I add the dll
directly I get the error:
The name '*' does not exist in the current context
FieldOps.DNX Core 5.0
Here's what part of my project.json
looks like where the library added is called "MyLibrary":
"frameworks": {
"dnx451": {
"frameworkAssemblies": {
"System.Runtime.Serialization": "4.0.0.0",
"System.ServiceModel": "4.0.0.0"
},
"dependencies": { "MyLibrary": "2.2.0" }
},
"dnxcore50": {
"dependencies": {
"System.Runtime.Serialization.Primitives": "4.1.0-beta-23516",
"System.ServiceModel.Primitives": "4.1.0-beta-23516",
"System.ServiceModel.Http": "4.0.11-beta-23516",
"System.ServiceModel.NetTcp": "4.1.0-beta-23516",
"System.ServiceModel.Duplex": "4.0.1-beta-23516",
"System.ServiceModel.Security": "4.0.1-beta-23516",
"System.Net.NameResolution": "4.0.0-beta-23516",
"System.Net.Security": "4.0.0-beta-23516",
"System.Security.Principal.Windows": "4.0.0-beta-23516",
"System.Diagnostics.Tools": "4.0.1-beta-23516"
}
}
},
来源:https://stackoverflow.com/questions/34661624/add-dll-to-mvc6-or-use-old-web-service