As a follow up to my post on getting the DataGridView and UltraNav/IBM scroll button to work, I’ve created a simple component that makes adding UltraNav support throughout your app easy. The code is contained in a class called UltraNavScrollHelper.
Here are two usages:
A) Use with DataGridView
public class myDGV : DataGridView
private UltraNavScrollHelper scrollHelper;
scrollHelper = new UltraNavScrollHelper(this, this.HorizontalScrollBar, this.VerticalScrollBar);
protected override void Dispose(bool disposing)
B) Use at design time with scroll bar controls
- Create panel
- drag and drop horizontal and vertical scroll bar controls in the panel
- drag and drop the UltraNavScrollHelper component from the toolbox
- Set the UltraNavScrollHelper Control property to the panel
- Set the UltraNavScrollHelper HorizontalScrollBar and VerticalScrollBar properties to the horizontal and vertical scroll bar controls on the panel.