ReoGrid Forum

Fast and powerful .NET Spreadsheet Component

You are not logged in.

Announcement

This forum has been archived and no longer accepts new user registrations. Please report your questions, problems, and feedback to the issue page of ReoGrid on GitHub. Thank you for your cooperation.

https://github.com/unvell/ReoGrid/issues

#1 2016-04-08 06:41:44

asparatu
Member
Registered: 2014-08-20
Posts: 196

Mouse Scroll Question

Hello Jing,
   Can you scroll horizontal in the grid, if i use the mouse scroll event?

Shane

Offline

#2 2016-04-08 08:28:54

Jingwood
Moderator
From: jing at reogrid.net
Registered: 2014-06-03
Posts: 615

Re: Mouse Scroll Question

Hi Shane, you can hold shift key and scroll mouse to horizontally scroll.

Offline

#3 2016-04-08 12:00:46

asparatu
Member
Registered: 2014-08-20
Posts: 196

Re: Mouse Scroll Question

Hello Jing,
  Ok. Is there anyway to make do that on default.. like override some event because there are couple sheet i just want scroll horizontally.

Shane

Offline

#4 2016-04-09 08:31:46

Jingwood
Moderator
From: jing at reogrid.net
Registered: 2014-06-03
Posts: 615

Re: Mouse Scroll Question

The whole test code is following, it requires to use an inherited class from ReoGridControl and add its instance on form.

Imports unvell.ReoGrid

Public Class Form8
	Private Sub Form8_Load(sender As Object, e As EventArgs) Handles MyBase.Load
		Dim grid As New MyReoGridControl() With {.Dock = DockStyle.Fill}

		Me.Controls.Add(grid)
	End Sub
End Class

' Customize control inherted from ReoGridControl
Class MyReoGridControl
	Inherits ReoGridControl

	Private Const WM_VWHEEL As Int32 = &H020A
	Private Const WM_HWHEEL As Int32 = &H020E

	Protected Overrides Sub WndProc(ByRef m As Message)
		If m.Msg = WM_VWHEEL Then
			m.Msg = WM_HWHEEL
		End If

		MyBase.WndProc(m)
	End Sub
End Class

Last edited by Jingwood (2016-04-09 08:32:16)

Offline

Board footer

Powered by FluxBB