|
ctl32_trackbar |
ctl32_trackbar: overview | members | pictures MSDN .NET System.Windows.Forms.TrackBar This visual class provides a trackbar control that can be used in VFP9. This class uses the Windows API to create a true Windows Common Controls trackbar, with full Themes compliance, just a couple of files to add to your project, No DLLs, no FLLs, no OCXs. The following files should be added to your project, copy all the files to the same folder: ctl32.h This class is based in the ctl32_controlbase Windows Common Controls abstract class. The TrackBar control (also sometimes called a "slider" control) is used for navigating through a large amount of information or for visually adjusting a numeric setting. The TrackBar control has two parts: the thumb, also known as a slider, and the tick marks. The thumb is the part that can be adjusted. Its position corresponds to the
The TrackBar is a scrollable control similar to the ScrollBar control. You can configure ranges through which the value of the ctlValue property of a track bar scrolls by setting the ctlMinimum property to specify the lower end of the range and the ctlMaximum property to specify the upper end of the range. The ctlLargeChange property defines the increment to add or subtract from the ctlValue property when clicks occur on either side of the scroll box. The track bar can be displayed horizontally or vertically. You can use this control to input numeric data obtained through the ctlValue property. You can display this numeric data in a control or use it in code.
The key properties of the TrackBar control are ctlValue, ctlTickFrequency, ctlMinimum, and ctlMaximum. ctlTickFrequency is the spacing of the ticks. ctlMinimum and ctlMaximum are the smallest and largest values that can be represented on the track bar.
Two other important properties are ctlSmallChange and ctlLargeChange. The value of the ctlSmallChange property is the number of positions the thumb moves in response to having the LEFT or RIGHT ARROW key pressed. The value of the ctlLargeChange property is the number of positions the thumb moves in response to having the PAGE UP or PAGE DOWN key pressed, or in response to mouse clicks on the track bar on either side of the thumb.
An interesting fact about this class is that trackbars inside a pageframe page look like they should, unlike trackbars in the .NET Framework, that don't have the page gradient background:
Trackbars in a VFP form:
Trackbars in a .NET form:
See Also: |
|
|
|