This Object TScrollBox represents a scrolling area (a scroll box) on a form. This object is like a TPanel With a scrolling area.
Description
Use TScrollBox to create a scroll box in a window. This object is similar to theTPanel in that it can put a border around other objects but it has other uses also. It 'owns' the objects placed on it and provide a scrolling area. This means that if you set the Visible property of the TScrollBox to .False. all object that are on the TScrollBox, automatically become invisible also. The same applies to the Enabled property. This can be very useful when you know you want to effect a group of objects all the same way at the same time.
Note : A scroll box can contain objects, such as TButton and TCheckBox objects. Use it as a scroling area on your form.
PALETTE ICON
PROPERTIES
The following are the properties that apply to this object. Some are defined in Common Properties and are linked to their appropriate page.
Appearance
Behavior
Font
Hint
Misc
Other
BevelInner | This will effect the look of the panel. The options are: bvLowered, bvNone (the default value), bvRaised and bvSpace. |
BevelOuter | This will also effect the look of the panel. The options are: bvLowered, bvNone, bvRaised (the default value) and bvSpace. |
BevelWidth | This is how wide the bevel is in pixels. The default value is 1. |
BorderStyle | By manipulating all four of these properties (BevelInner, BevelOuter, BevelWidth and BorderStyle) you can completely change the look of the panel. |
HorzScrollBar | Use HorzScrollBar to hide, show, or manipulate the vertical scroll bar for the scrolling windowed control. Options are. |
Button Size
Color
Increment
Margin
ParentColor
Range
Size
ThumbSize
Tracking
Visible
VertScrollBar Use VertScrollBar to hide, show, or manipulate the vertical scroll bar for the scrolling windowed control. Options are.
Button Size
Color
Increment
Margin
ParentColor
Range
Size
ThumbSize
Tracking
Visible
Position
COMMENTS
If you decide to put a TPanel on your form after other objects have already been added that you want to move to the panel, you can't just move them to the panel. You can, however, copy it (click on the object, right click and choose copy or press CTL+C) and then paste it on the panel (right click on the panel and choose Paste or CTL+V) and then delete the original object.
EVENTS
This object has a single event that is called if your user clicks on the object. This event looks to your program for a special label. It is made up of the object Name, a period (.) and the Event name (Click). The full event name would be ObjectName.Click:. You would not return a value from the program, just a simple RET is all that is required. So, the user clicks on the object, if the event label exists the routine is called, you return from the routine, and the user has control again.
NOTE: You can have multiple objects call the same routine by 'stacking' the event labels on top of each other. For example, if you had two buttons you wanted to call the same event, you could do the following:
btnFirstButton.click:
btnSecondButton.click:
//event routine code would go here.
ret
The labels are not part of the code executed. They are just place keepers and tell the program where to go.
Page url: http://www.cassoftware.com/tas/manual/tscrollbox.htm