![]() |
MouseWheel event not firing
Hello,
I have a winform UserControl that i created. It contains a flowlayoutpanel that i want to enable scrolling on. I have tried attaching the event handler to to this panel, to the usercontrol itself, etc., but the event never fires. this.MouseWheel += new MouseEventHandler(RecentActivity_MouseWheel); this.flowPanel.MouseWheel += new MouseEventHandler(RecentActivity_MouseWheel); Any ideas? tx :-) |
MouseWheel event not firing
I was able to resolve this (finally) - the solution is simple but not
appearant. 1.) On The click event of the control you want to scroll (ie: flowlayoutpanel), simply set focus to that control - thats it! Even when clicking on the control or using the scrollbar, it was not considered as 'having focus' "aiKeith" wrote: Hello, I have a winform UserControl that i created. It contains a flowlayoutpanel that i want to enable scrolling on. I have tried attaching the event handler to to this panel, to the usercontrol itself, etc., but the event never fires. this.MouseWheel += new MouseEventHandler(RecentActivity_MouseWheel); this.flowPanel.MouseWheel += new MouseEventHandler(RecentActivity_MouseWheel); Any ideas? tx :-) |
All times are GMT +1. The time now is 05:30 AM. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2006 OutlookBanter.com