错误之程序D层丢了

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/liuyubibn/article/details/84933869

程序D层丢了——深入理解“未处理的FileNotFoundException”

来自 https://blog.csdn.net/yxflovegs2012/article/details/42780527

启动项中没有 DAL.dll 文件,你可以通过引用添加此项目,或者手动将dll文件copy到web启动项的bin目录下即可或者右键DAL类库-属性-生成-浏览,然后选择UI层的bin文件夹,然后保存,这样每次修改就不用手动去copy了。

来自 https://blog.csdn.net/qq719365064/article/details/52925268

错误 1 “DAL.LoginDAL”不实现接口成员“IDAL.LoginIDAL.selectUser(Entity.UserInfo)” F:\vs例子\七层\loginSolution\DAL\LoginDAL.cs 12 18 DAL

未处

程序D层丢了——深入理解“未处理的FileNotFoundException”

来自 https://blog.csdn.net/yxflovegs2012/article/details/42780527

启动项中没有 DAL.dll 文件,你可以通过引用添加此项目,或者手动将dll文件copy到web启动项的bin目录下即可或者右键DAL类库-属性-生成-浏览,然后选择UI层的bin文件夹,然后保存,这样每次修改就不用手动去copy了。

来自 https://blog.csdn.net/qq719365064/article/details/52925268

错误 1 “DAL.LoginDAL”不实现接口成员“IDAL.LoginIDAL.selectUser(Entity.UserInfo)” F:\vs例子\七层\loginSolution\DAL\LoginDAL.cs 12 18 DAL

未处理System.IO.FileNotFoundException
HResult=-2147024894
Message=未能加载文件或程序集“DAL”或它的某一个依赖项。系统找不到指定的文件。
Source=mscorlib
FileName=DAL
FusionLog==== 预绑定状态信息 ===
日志: DisplayName = DAL
(Partial)
警告: 为程序集提供了部分绑定信息:
警告: 程序集名称: DAL | 域 ID: 1
警告: 当仅提供程序集显示名称的一部分时,将发生部分绑定。
警告: 这可能导致联编程序加载错误的程序集。
警告: 建议为程序集提供完全指定的文字标识,
警告: 并由简单名称、版本、区域性和公钥标记组成。
警告: 有关此问题的详细信息和常见解决方案,请参见白皮书 http://go.microsoft.com/fwlink/?LinkId=109270。
日志: Appbase = file:///F:/vs例子/七层/loginSolution/UI/bin/DebSystem.IO.FileNotFoundException
HResult=-2147024894
Message=未能加载文件或程序集“DAL”或它的某一个依赖项。系统找不到指定的文件。
Source=mscorlib
FileName=DAL
FusionLog==== 预绑定状态信息 ===
日志: DisplayName = DAL
(Partial)
警告: 为程序集提供了部分绑定信息:
警告: 程序集名称: DAL | 域 ID: 1
警告: 当仅提供程序集显示名称的一部分时,将发生部分绑定。
警告: 这可能导致联编程序加载错误的程序集。
警告: 建议为程序集提供完全指定的文字标识,
警告: 并由简单名称、版本、区域性和公钥标记组成。
警告: 有关此问题的详细信息和常见解决方案,请参见白皮书 http://go.microsoft.com/fwlink/?LinkId=109270。
日志: Appbase = file:///F:/vs例子/七层/loginSolution/UI/bin/Debug/
日志: 初始 PrivatePath = NULL
调用程序集: Factory, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null。

日志: 此绑定从 default 加载上下文开始。
日志: 正在使用应用程序配置文件: F:\vs例子\七层\loginSolution\UI\bin\Debug\UI.vshost.exe.Config
日志: 使用主机配置文件:
日志: 使用 C:\Windows\Microsoft.NET\Framework\v4.0.30319\config\machine.config 的计算机配置文件。
日志: 此时没有为引用应用策略(私有、自定义、分部或基于位置的程序集绑定)。
日志: 尝试下载新的 URL file:///F:/vs例子/七层/loginSolution/UI/bin/Debug/DAL.DLL。
日志: 尝试下载新的 URL file:///F:/vs例子/七层/loginSolution/UI/bin/Debug/DAL/DAL.DLL。
日志: 尝试下载新的 URL file:///F:/vs例子/七层/loginSolution/UI/bin/Debug/DAL.EXE。
日志: 尝试下载新的 URL file:///F:/vs例子/七层/loginSolution/UI/bin/Debug/DAL/DAL.EXE。

StackTrace:
在 System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
在 System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
在 System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
在 System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean forIntrospection)
在 System.Reflection.RuntimeAssembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
在 System.Reflection.Assembly.Load(String assemblyString)
在 Factory.LoginFactory.CreateUser() 位置 f:\vs例子\七层\loginSolution\Factory\LoginFactory.cs:行号 20
在 BLL.LoginBLL.UserBLL(UserInfo UserInfo) 位置 f:\vs例子\七层\loginSolution\Bll\LoginBLL.cs:行号 17
在 Facade.LoginFacade.SelectUser(UserInfo user) 位置 f:\vs例子\七层\loginSolution\Facade\LoginFacade.cs:行号 19
在 UI.Form1.butOK_Click(Object sender, EventArgs e) 位置 f:\vs例子\七层\loginSolution\UI\Form1.cs:行号 90
在 System.Windows.Forms.Control.OnClick(EventArgs e)
在 System.Windows.Forms.Button.OnClick(EventArgs e)
在 System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
在 System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
在 System.Windows.Forms.Control.WndProc(Message& m)
在 System.Windows.Forms.ButtonBase.WndProc(Message& m)
在 System.Windows.Forms.Button.WndProc(Message& m)
在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
在 System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
在 System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
在 System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)
在 System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
在 System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
在 System.Windows.Forms.Application.Run(Form mainForm)
在 UI.Program.Main() 位置 f:\vs例子\七层\loginSolution\UI\Program.cs:行号 19
在 System.AppDomain._nExecuteAssembly(RuntimeAssembly assembly, String[] args)
在 System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
在 Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
在 System.Threading.ThreadHelper.ThreadStart_Context(Object state)
在 System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
在 System.Threading.ThreadHelper.ThreadStart()
InnerException:

猜你喜欢

转载自blog.csdn.net/liuyubibn/article/details/84933869
今日推荐