I am enhancing a Windows Forms application which displays TIFF images. The application has a Picturebox on top of a Panel and displays 1 image page at a time (there are thumbnails which users can click on to view a particular image). If there are multiple images the user wants to see the next one by using an event such as the mouse wheel. We currently have previous and next arrow button / function but they want more)
What I believe I should do is find out if the image is at the bottom during a mouse wheel event and then select the next one. Also, same thing the opposite way, get the previous image and scroll to the bottom if they use the mouse wheel going up.
Also, I need to note that the image may be larger than the Panel so a vertical Scroll bar appears. So, when using the mouse wheel, need to make sure it is at the bottom.
Thanks in advance.
I found a resolution to this
1) created a new variable to store the previous Vertical Scroll Value (prevVScrollVal).
2) Create a new MouseEventHandler
3) in Mouse Event Handler identify if up or down by looking @ the e.delta then check if the previous scroll value is the same and switch images accordingly.