- Imports System.Reflection
- Try
- Dim Asm As Assembly = Assembly.LoadFrom("DLL名称.dll")
- Dim frm1 As Form = DirectCast(Asm.CreateInstance("DLL命名空间.窗体名称"), Form)
- frm1.Show()
- Catch ex As Exception
- MsgBox("找不到窗体或载体不存在!" + ex.Message, MsgBoxStyle.Exclamation, "程序错误")
- End Try
最近运气不坏~呵呵~解决了很多以前自已解决不了的问题~