Is it bad practice to write inline event handlers ?
For me, I prefer use it when I want to use a local variable in the event handler like the following:
I prefer
It's absolutely fine - although there are two caveats:
Typically I only inline really simple event handlers - for anything more involved, I use lambda expressions (or anonymous methods) to subscribe with a call to an method with a more appropriate method:
// We don't care about the arguments here; SaveDocument shouldn't need parameters
saveButton.Click += delegate { SaveDocument(); };