G
Guest
This is my code:
FileStream fs = new FileStream(@"C:\Documents and Settings\Berdoues\Mes
documents\VisualStudioProjects\Application_Test_WindowsForm\LoadAssembly\CaptureControl.exe",FileMode.Open);
BinaryReader br = new BinaryReader(fs);
byte[] byteload = br.ReadBytes(Convert.ToInt32(fs.Length));
fs.Close();
br.Close();
Assembly asm = Assembly.Load(byteload);
object o = asm.CreateInstance("CaptureControl");
MethodInfo mi = asm.EntryPoint;
if(mi != null)
{
mi.Invoke(o,null);
}
It doesn'work.
"capturecontrol" is the name of my assembly and the namespce of my class
I don't understand the parameter of mi.Invoke(?,?);
Thank you for your help and patience!
wavemill
FileStream fs = new FileStream(@"C:\Documents and Settings\Berdoues\Mes
documents\VisualStudioProjects\Application_Test_WindowsForm\LoadAssembly\CaptureControl.exe",FileMode.Open);
BinaryReader br = new BinaryReader(fs);
byte[] byteload = br.ReadBytes(Convert.ToInt32(fs.Length));
fs.Close();
br.Close();
Assembly asm = Assembly.Load(byteload);
object o = asm.CreateInstance("CaptureControl");
MethodInfo mi = asm.EntryPoint;
if(mi != null)
{
mi.Invoke(o,null);
}
It doesn'work.
"capturecontrol" is the name of my assembly and the namespce of my class
I don't understand the parameter of mi.Invoke(?,?);
Thank you for your help and patience!
wavemill