Type | Description | |||
ScrollBarsEnum | A ScrollBarsEnum expression that identifies which scroll bars are visible. |
Use the ScrollBars property to show, enable or disable the control's scroll bars. By default, the ScrollBars property is exBoth, so both scroll bars are used if necessarily. For instance, if the ScrollBars property is exNone the control displays no scroll bars. Use the ScrollPos property to get the control's scroll position. Use the EnsureVisibleItem method to ensure that an item fits the control's client area. Use the EnsureVisibleColumn method to ensure that a specified column fits the control's client area. Use the Scroll method to scroll programmatically the control. Use the ScrollOrderParts property to customize the order of the buttons in the scroll bar. The RightToLeft property flips the order of the control's elements from right to left. Use the FirstVisibleDate property to scroll the chart's date.
The following screen shots shows all 3 scrollbars that can be visible in the control:
The control provides up to 3 scroll bars. The vertical scroll bar is displayed on the right side of the control ( RightToLeft property is False ) and it scrolls the items, rows ( nodes ). The other 2 scroll bars are for scrolling the columns section and the chart area. The ScrollBar property of the Chart object specifies whether the chart displays the horizontal scroll bar.
If the Scroll(exScrollVTo) does not work please check if the ScrollBars property includes the exVScrollOnThumbRelease, and use a code like follows:
With G2antt1 .ScrollBars = .ScrollBars And Not exVScrollOnThumbRelease .Scroll exScrollVTo, 10000 .ScrollBars = .ScrollBars Or exVScrollOnThumbRelease End With
The code removes temporary the exVScrollOnThumbRelease flag from the ScrollBars property, performs the scrolling ( jump to row 10000 ) , and restore back the exVScrollOnThumbRelease flag.
The following VB sample scrolls vertically the control to row 100:
G2antt1.Scroll exScrollVTo, 100