Basically I have a panel in a winforms project that contains a collection of picture boxes. The panel and picture boxes are all created at runtime and added to an existing panel on the form. The issue I have is that on a touchscreen win 7 PC, if you touch the gap between the picture boxes (the underlying panel itself) and drag to scroll vertically, it works, but when you touch one of the picture boxes it doesn't (I should also mention I am handling the onclick event of the picture box to do something else as well in case that makes things more complicated) How do I achieve scrolling on any area of the panel or the controls contained within it?
Asked
Active
Viewed 870 times
0
-
1It would help to see the relevant code. But picture boxes don't have scrolling, and if you touch the picture box, it's getting the events, so you'd have to pass it through to the control that actually contains them and _can_ scroll. – DonBoitnott Jun 06 '13 at 16:42
-
"I should also mention I am handling the onclick event of the picture box" Add a line of code in there to give focus to the parent panel and it should work as expected... – Idle_Mind Jun 06 '13 at 17:41