mirc already has an on error event, but that only responds to server error messages, on connect etc. There is no way to custom handle when mIRC itself has an error. I noticed the new goto :error thing, which is actually very nice, but there are some that can't be caught that way. The best example:
unable to resolve local host.
That's not a server error, that's simply a mirc error. It happens sometimes, preventing DCC sends, and can be resolved by typing /localinfo. Of course I have no way of automating a /localinfo response when the error occurs, AND I have no way of typing /localinfo and halting the output, which means if I repeatedly use /localinfo on a timer I'm flooded with messages in the status window. So you see the problem.
What mirc needs is an actual on error event, so that someone can automatically respond when it happens. Unless someone can think of another way out of this particular problem.