private void button1_Click(object sender, System.EventArgs e)
{
string DllPath = Application.StartupPath + @"/someDLL.dll";
System.Reflection.Assembly assmble = System.Reflection.Assembly.LoadFile(DllPath);
string typeName = "someDLL.frmDll";//namespace + formClassName
object tmpObj = assmble.CreateInstance(typeName);
if (tmpObj is Form)
{
Form subForm = (Form)tmpObj;
subForm.MdiParent = this;
subForm.Show();
}
}
{
string DllPath = Application.StartupPath + @"/someDLL.dll";
System.Reflection.Assembly assmble = System.Reflection.Assembly.LoadFile(DllPath);
string typeName = "someDLL.frmDll";//namespace + formClassName
object tmpObj = assmble.CreateInstance(typeName);
if (tmpObj is Form)
{
Form subForm = (Form)tmpObj;
subForm.MdiParent = this;
subForm.Show();
}
}