the example your'e trying to follow is a bad one to follow for you case... it's a good one to follow if and only if you want to handle multiple buttons from the same handler, which isn't common. It's rare to want to use the sender parameter. Normally you just create the button or control (what ever it may be) and you simply create the event handler you want to handle (be it a click or onChange, or what ever) and you write the code you need in that event handler.

since you are writing an add-in for Excel, you may want to look at examples/books that deal specifically with Office Add-ins and not at VB in general as there are going to be some differences.


-tg