farklem
Aug 15th, 2005, 12:11 PM
I have been trying to use MethodInvoker to run a method but im not sure how to get the syntax right so it passes a string to the method. As of now I get this error when trying to build: C:\Documents and Settings\Administrator\Desktop\IRCb\frmServer.cs(590): Method 'IRCb.frmServer.RecieveCommand(string)' does not match delegate 'void System.Windows.Forms.MethodInvoker()'
public void RecieveCommand(string Command)
{
Console.WriteLine(Command);
}
public void InvokeRecieve()
{
MethodInvoker MI = new MethodInvoker(RecieveCommand);
this.BeginInvoke(MI);
}
Thanks :)
public void RecieveCommand(string Command)
{
Console.WriteLine(Command);
}
public void InvokeRecieve()
{
MethodInvoker MI = new MethodInvoker(RecieveCommand);
this.BeginInvoke(MI);
}
Thanks :)