Hi John,
if WM_DESTROY is working for you, that's fine. However, unless your component needs to work in a variety of different frameworks I would tend to add this features to the form class itself. Right now you have code that is triggered when a window message is sent which is completely outside the form or any of the classes used in the form. This makes it hard to discover this code for anyone who doesn't know about this feature. You also might have a couple of situations where the window function is executed unexpectedly, for instance after an application error.
--
Christof