title: .NET Focus() on WinForm control makes scrollbar move down
body: <p><strong>The link to the code is here on my github (was too long to post here):</strong></p>
  
  <p><a href="https://github.com/alpizano/UI-Scrollbar/blob/master/ScreenLogic.vb" rel="nofollow noreferrer">https://github.com/alpizano/UI-Scrollbar/blob/master/ScreenLogic.vb</a></p>
  
  <p><em>I also added a README.md that has the Controls labeled on the screen</em></p>
  
  <p>I am interning and trying to fix a bug with software (using Visual Studio and code is in VB.Net). It is basically a Windows Form frame (analogous to a "Panel"?) (fraAddress) that imports a sub-screen called "AddressEdit" which can be simply viewed in the image below as the Address box that contains the street (streStreet), city (streCity), state (streState), ZIP (streZip), county (streCounty) and country (streCountry) fields. The "Description" ComboBox and "SiteID" TextBox are part of the frame (fraAddress) but NOT part of the subscreen "AddressEdit". The TextBoxes are actually called StringEdits and the List Views are called VirtualListViews in this software designer.</p>
  
  <p>The issue is, anytime you use the left vertical navigation menu to switch screens (say going from "Account Detail" to "Opportunities" then back to "Account Detail"), if you are clicked inside the "AddressEdit", the scrollbar to the right (fraDragDrop frame) will move <strong>DOWN</strong> (as seen in the 2nd image below) when you return to the "Account Detail" screen. However, when inside any other controls, like "Structure" list, or the "Comments" TextBox, and switching screens via the left navigation menu then coming back to "Account Detail" screen, the scrollbar is <strong>FINE</strong> and does <strong>NOT MOVE</strong>.
  <a href="https://i.stack.imgur.com/cRi4I.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/cRi4I.png" alt="enter image description here"></a></p>
  
  <p><a href="https://i.stack.imgur.com/YLpuv.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/YLpuv.png" alt="enter image description here"></a></p>
  
  <p>Do any experienced .NET devs with WindowsForms/Controls have any idea what it could be?</p>
  
  <p>There is a function called "Activated" that is called every time screen is switched to "AccountDetail", and I tried manually setting focus to the "AddressEdit" but to no avail... I feel like the fact that this is "AddressEdit" is a sub-screen and trying to Focus() is causing some glitch (none of the other controls are sub-screens and work fine).</p>
  
  <p>Even when setting the focus() to say, the "Account name" TextBox at the top of the page manually when the page reloads and the user is clicked inside the "AddressEdit", it will indeed focus on the TextBox.... but the scrollbar will STILL slide down and block the top of the frame out of view....</p>
  
  <p>I'll take any help I can on this... ;)</p>