I've got an delegate and event with an out parameter:
public delegate void ExampleDelegate(object sender, EventArgs e, out string value);
public event ExampleDelegate Example;
When I'm trying to handle the event:
mg.Example += (sender, e, val) =>
{
//do stuff
};
I'm getting the error Parameter 3 must be declared with the 'out' keyword
When I'm throwing in the suggested out keyword like so:
mg.Example += (sender, e, out val) =>
{
//do stuff
};
I'm getting and extra error the type of namespace name 'val' could not be found..etc
What am I doing wrong?