I have a VS2012 Express (Desktop) MVVM project, where the Model (EF5 Code First) classes are stored in an independent C# DLL.
I am now planning on accessing parts of the same database over the internet using ASP.NET (with which I have much less experience than with programming for Windows). I am therefore creating an ASP.NET View which will use the same Model and VM.
Can I simply use the same DLL in my ASP.NET project, or am I more limited with the code that will run in ASP.NET compared with a Windows DLL?
Unless you're running in Medium Trust (which is highly discouraged), code running in ASP.Net can load any DLL it wants. (including P/Invoke)
It's all the same .Net; the only difference is whether it's running in an interactive session or in IIS.
Note that running UI code will break things.
使用ASP.Net中的相同DLL应该不是问题,但我想知道如何在ASP.Net中使用VideModel代码,在您的ASP中不支持ViewModel的属性更改通知机制(INotifyPropertyChanged的实现)页。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.