Board index » delphi » Register/Unregister and destroy
j...@stack.urc.tue.nl (Jan Oonk)
![]() Delphi Developer |
Sun, 20 Sep 1998 03:00:00 GMT
Register/Unregister and destroy
I have a ImageList and a pointer Buttons to this ImageList. When the
ImageList is destroyed the Buttons pointer will of course not be valid anymore! Is there a way that when the ImageList will be/is destroyed it will call a user defined routine so I can update the Buttons pointer to nill? I know the ImageList.OnChange will be called when it's destroyed but also of course when it's changed in any way (for example a new picture). So how can I identify if the OnChange is a destroy? (I know there's a csDestroying in the component status). Another problem arises when you have multiple objects sharing one ImageList, because the ImageList.OnChange can only have one Routine hooked!? The solution to many of these questions are the Register/Unregister Can anyone help me? Thanks in advance... Please reply to my email address (j...@stack.urc.tue.nl) because I are CU! Jan Oonk |