TargetParameterCountException is thrown on a ToolStripMenuItem click

  • Thread starter Thread starter Justin Cherniak
  • Start date Start date
J

Justin Cherniak

I have a ToolStrip item which fires a function when clicked. The
function will run to completion without any problems (if I set a
breakpoint at the closing brace, no exception has been fired), but
once it returns, I get a TargetParameterCountException in mscorlib. I
cannot for the life of me figure out why and I'm hoping someone here
might be able to help.

Here is the relevant code (although I don't think it has any effect)


ToolStripMenuItem resetLib = new ToolStripMenuItem("Reset Library",
null, new EventHandler(ResetLibraryClick));

void ResetLibraryClick(object o, EventArgs e)
{
player.Stop();
player.Playlist = null;
library = new Library();
library.LibraryChanged += new
EventHandler(library_LibraryChanged);
library.Save();
Tracks = library.Tracks;
UpdateListboxes();
}

Thanks in advance,
Justin Cherniak
 
The problem was found elsewhere in the code, so you can safely ignore
this post...

Thanks,
Justin
 
Back
Top