peteinman
September 6th, 2002, 09:11 AM
I would like to write a set of classes for handling different types of textboxes.
My base class ( myTextBoxBase ) would need have a method to set the tooltip, so I will have a user control containing a textbox and a tooltip control.
I would then like to derive another class from myTextBoxBase which would allow me to handle the right click mouse button. It would still have the ability to handle tooltips, as it inherited from myTextBoxBase.
It all sounds reasonable, but I cannot get it to work.
As a test I simplified my functionality, and created myTextBoxBase with the tooltip functionality. All works fine.
I then derived another textbox form myTextBoxBase, and all this would do is be a textbox with a Red background.
It has tooltip functionality but doesn't have a Red background.
When I tried to get the right mouse button handling, again it had the tooltip functionality but not the right mouse button.
All I want to end up with in my test is
Am I doing anything obviously wrong ? Do I need to call base constructors?
Anyone any idea what I'm missing?
Pete
My base class ( myTextBoxBase ) would need have a method to set the tooltip, so I will have a user control containing a textbox and a tooltip control.
I would then like to derive another class from myTextBoxBase which would allow me to handle the right click mouse button. It would still have the ability to handle tooltips, as it inherited from myTextBoxBase.
It all sounds reasonable, but I cannot get it to work.
As a test I simplified my functionality, and created myTextBoxBase with the tooltip functionality. All works fine.
I then derived another textbox form myTextBoxBase, and all this would do is be a textbox with a Red background.
It has tooltip functionality but doesn't have a Red background.
When I tried to get the right mouse button handling, again it had the tooltip functionality but not the right mouse button.
All I want to end up with in my test is
Am I doing anything obviously wrong ? Do I need to call base constructors?
Anyone any idea what I'm missing?
Pete