Disable Scroll using mousewheel in grid

Posted by: kshitizkumar on 27 March 2020, 2:17 am EST

  • Posted 27 March 2020, 2:17 am EST


    I am looking to disable scrolling in the grid through mouse wheel and want it to scroll only using an external scrollbar that I have applied in the code. I have two grids(one normal grid, one with 7 splits) and I am controlling the scrolling through an external scrollbar and whenever user tries to use mouse wheel both the grid goes out sync. I want to disable the scrolling using mouse wheel.

    Can you please let me know how can I achieve that ?

    Early response will be much appreciated since I am working on a production issue.

  • Marked as Answer

    Replied 29 March 2020, 4:33 pm EST

    Hi Kshitz,

    As there is no direct property or method to suppress the default scrolling using mouse wheel so you need to create custom control inheriting C1TrueDBGrid to suppress default scrolling using MouseWheel.

    Please go through the attached sample implementing the same and let me know if this helps or not.

    Prabhat Sharma.
  • Replied 29 March 2020, 7:40 pm EST

    Thanks Prabhat for your help. Works like a dream.
Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels