![]() |
Source Code |
![]() |
![]() |
2 | Common Controls Library |   |
NOTE:
this code has been superceded by the version at the new site.
|
  |
Flat Scroll Bars |
  | ||
  |   |
|
  | |
  |
This sample requires the SSubTmr.DLL component. Make sure you have loaded and registered this before trying the FlatSBar project. The sample project contains a new custom control designed in VB5, cFScroll.ocx. This control is designed to be a drop-in
replacement for the standard VB scroll bar. Flat Scroll bars are only available if you have the version of COMCTL32.DLL supplied with
IE4.0. This DLL can also be downloaded separately from the
Microsoft site. (Note you must register with MSDN to follow this link, but it is free).
The following table summarises the new and changed methods for cFScroll.ocx compared to the standard VB scroll bar:
|
  | ||
  | Method | Change | Description |   |
  | ActiveBar | New |
The cFScroll.ocx control allows you to have:
![]() In order to specify which scroll bar you are making settings for, set the ActiveBar to either:
|
  |
  | BorderStyle | New |
Sets the border style for the control. This is only really any use when you have both scroll bars on (see above) |
  |
  | CanBeFlat | New |
This Read-only property returns whether the system supports flat scroll bars or not. |
  |
  | Max | Changed |
The Maximum setting can be a full 32 bit value rather than being limited to 16 bits. |
  |
  | Min | Changed |
The Minimum setting can be a full 32 bit value rather than being limited to 16 bits. |
  |
  | Orientation | New |
Rather than have separate controls for Horizontal and Vertical scroll bars, this control provides both scroll types in the same control. In addition, you can have both Horizontal and Vertical scrolling in the same control. The settings for this are:
|
  |
  | Style | New |
This property allows you to set the control's appearance, as shown in the diagrams at the top of the page. The settings for this are:
|
  |
  | AutoRedraw, hDC, Refresh, ScaleWidth, ScaleHeight | New |
These properties are provided to allow you to draw into the client (non-scroll bar) area of the control with API drawing methods. The methods work in the same way as for a PictureBox. |
  |
  |
|
  |
![]() |
|
About Contribute Send Feedback Privacy
|