Which is more correct and why?
Control.BeginInvoke(new Action(DoSomething), null);
private void DoSomething()
{
MessageBox.Show("What a great post");
}
or
Control.BeginInvoke((MethodInvoker)delegate { MessageBox.Show("What a great post"); });
I kinda feel like i am doing the same thing, so when is the right time to use MethodInvoker vs Action, or even writing a lamda?
edit: I know that really there isnt much of a difference between writing a lamda vs Action, but MethodInvoker seems to be made for a specific purpose. Is it doing anything different?