I have a custom text box and I'm developing a notepad app. I want to dynamically write the zoom factor of the text box to the label. so I need to use the textbox mousewheel event but it doesn't light up so it doesn't go inside the mousewheel. what should I do ?
CodePudding user response:
Code looks ok to me.
Place your mouse pointer very close to the edge of the textbox and you'll see it works.
If you want to handle the events over the entire area you should probably do something like:
this.txtBoxKryptonText.ContainedControl.MouseWheel
= new System.Windows.Forms.MouseEventHandler(this.txtBoxKryptonText_MouseWheel);