System.Windows.Forms.Form has only one scroll event. Scrolling , but you need to recognize scrolling and scrolling down. Could you tell me how to do this?
Use the passed Properties properties of OldValue and NewValue for System.Windows.Forms.ScrollEventArgs to determine the scroll direction.
private void dgv_Scroll(object sender, ScrollEventArgs e) { if (e.OldValue > e.NewValue) { // here up } else { // here down } }
Checkout ScrollEventArgs Class and this answer .
ScrollEventArgs
Source: https://habr.com/ru/post/1308540/More articles:solutions for rapid development of the interface? - language-agnostichttps://translate.googleusercontent.com/translate_c?depth=1&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1308536/attached-properties-to-avoid-custom-controls&usg=ALkJrhg9WgZQYGhwTzIiSjDYOmW48t8rhAHow to connect and send data in Bluetooth AS3 format? - actionscript-3Adding a column to the model at runtime (without additional tables) in rails - ruby | fooobar.comRails Architecture Issues - oopManipulate DisplayMember before displaying it - c #The correct way to write "ID" in SQL columns - sqlWhy is toInteger :: Int → Integer lazy? - haskellHow to change the font of the main objects in Delphi? - delphiWhich libraries use design patterns implemented using metaprogramming techniques at compile time? - c ++All Articles