VB.NET: Data Grid View Jumps to the Top of the Page When it Gains Focus
Posted on 2010-09-04
I have a Windows Form, containing a Panel with scroll bars. Within the Panel is a few text boxes at the top of the page and a Data Grid View with a lot of data in it. The Data Grid View starts about half way down the Panel and goes off the bottom, so you have to use the Panel scroll bars to view the bottom of the data.
This is the way it is supposed to look and work.
Unfortunately if the user goes onto the page and clicks a row close to the top, the Panel automatically scrolls so that the Data Grid View is at the top of the screen. It also selects a number of rows instead of just the clicked one.
Does anyone know of a solution to this, other than changing the structure of the form?
If you need any further information then please let me know.