|
|
|
|
|
- Default characteristics of border
- WLanguage properties that can be used with the Border type
- Type of line for the border
Border (Variable type) In french: Cadre
The Border type is used to handle a border programmatically. The characteristics of this border can be modified by several WLanguage properties. A Border type can be used: - in the controls of a window (Border property).
- in the cells of a Table control in a window (Border property of cells of Table controls).
- in the controls of a report (Border property).
Not available. - in the drawing functions (dBorder).
- in Excel cells (Border property of cells in an Excel document).
- in the paragraphs of a Word Processing document (Border property on the layout options of docParagraph variables).
Remark: For more details on the declaration of this type of variable and the use of WLanguage properties, see Declaring a variable.
// Define the characteristics of the borders for report controls MyBorder is Border MyBorder.Color = LightRed MyBorder.Thickness = 5 Â // Borders for the NumNbPage control in the report NumNbPage.Border = MyBorder // Modify the characteristics of the borders for the NumNbPage control NumNbPage.Border.Thickness = 1 Â // Get the characteristics of the borders for the NumNbPage control MyBorder2 is Border = NumNbPage.Border // Define the border characteristics MyBorder is Border MyBorder.Color = LightRed MyBorder.Thickness = 5 Â // Borders for the NumNbPage control in the report NumNbPage.Border = MyBorder // Modify the characteristics of the borders for the NumNbPage control NumNbPage.Border.TopLeftCorner.Width = 2 NumNbPage.Border.TopLeftCorner.Height = 3
Remarks Default characteristics of border By default, a border found in a report has the following characteristics: - thickness set to 0. The border is visible if the thickness is greater than 0. The border is invisible if the thickness is set to 0.
- black.
- solid line.
- no rounded corners.
- all the border edges are displayed.
To define the characteristics of a border through programming, use the border properties. WLanguage properties that can be used with the Border type The following properties can be used to handle Border variables. | | | Property name | Type used | Effect |
---|
BottomLeftCorner | | Characteristics of the lower-left corner: - Width property: width of border corner (real).
- Height Property: height of border corner (real).
Not supported in XLS cells. | BottomRightCorner | | Characteristics of the lower-right corner: - Width property: width of border corner (real).
- Height Property: height of border corner (real).
Not supported in XLS cells. | Color | Integer | Border color. This color can correspond to:This property can be used: - In edit mode: the color of all the borders changes.
- In read mode, this property returns:
- the color of the borders if all the borders have the same color.
- the ColorUndefined constant if all the borders do not have the same color.
| Edges | Integer constant | Returns and modifies the presence of edges. This property can correspond to a combination of the following options:- BorderNone: the border has no edge.
- BorderBottom: the border has a bottom edge.
- BorderRight: the border has a right edge.
- BorderLeft: the border has a left edge.
- BorderTop: the border has a top edge.
- BorderAll: all the border edges are displayed.
| Line | Integer constant | Returns and modifies the type of line for the border (see the next paragraph).- In edit mode, modifies the type of line for all borders.
- In read mode, returns:
- the type of line for the borders if this parameter is identical for all borders.
- the TypeUndefined constant if all the borders do not have the same line.
| LineBottom | | Characteristics of the bottom line: - Color property: Line color: This color can correspond to an RGB color (returned by RGB), or to a preset color.
- Thickness property (Real): Line thickness (in millimeters in printouts, and in pixels in graphic functions).
- Type property (Integer constant): Type of line (see the next paragraph).
The type of line will only be taken into account for frames where all corners are rounded and all edges have the same color and thickness.
Not supported in XLS cells. | LineLeft | | Characteristics of the left line: - Color property: Line color: This color can correspond to an RGB color (returned by RGB), or to a preset color.
- Thickness property (Real): Line thickness (in millimeters in printouts, and in pixels in graphic functions).
- Type property (Integer constant): Type of line (see the next paragraph).
The type of line will only be taken into account for frames where all corners are rounded and all edges have the same color and thickness.
Not supported in XLS cells. | LineRight | | Characteristics of the right line: - Color property: Line color: This color can correspond to an RGB color (returned by RGB), or to a preset color.
- Thickness property (Real): Line thickness (in millimeters in printouts, and in pixels in graphic functions).
- Type property (Integer constant): Type of line (see the next paragraph).
The type of line will only be taken into account for frames where all corners are rounded and all edges have the same color and thickness.
Not supported in XLS cells. | LineTop | | Characteristics of the top line: - Color property: Line color: This color can correspond to an RGB color (returned by RGB), or to a preset color.
- Thickness property (Real): Line thickness (in millimeters in printouts, and in pixels in graphic functions).
- Type property (Integer constant): Type of line (see the next paragraph).
The type of line will only be taken into account for frames where all corners are rounded and all edges have the same color and thickness.
Not supported in XLS cells. | Round | Real | Value of rounding for the corners. Corresponds to the radius of rounding. - In modification, modifies the rounding of all corners.
- In read mode, returns:
- the width and the height of corners if these parameters are identical for all corners.
- the RoundingUndefined constant if all the corners do not have the same width and height.
Not supported: - in the XLS cells.
- in the prargraphs of Word Processing documents.
| Thickness | Real | Returns and modifies the thickness of the border (in millimeters in the prints and in pixels in the graphic functions). - In edit mode, changes the thickness of all the borders.
- In read mode, returns:
- the thickness of the borders if the parameter is the same for all the borders.
- the ThicknessUndefined constant if all the borders do not have the same thickness.
Not supported in XLS cells. | TopLeftCorner | | Characteristics of the upper-left corner: - Width property: width of border corner (real).
- Height Property: height of border corner (real).
Not supported in XLS cells. | TopRightCorner | | Characteristics of the upper-right corner: - Width property: width of border corner (real).
- Height Property: height of border corner (real).
Not supported in XLS cells. |
These properties can be used: - on the Border variable. Example:
MyBorder is Border MyBorder.Color = LightRed MyBorder.Thickness = 5
- on the Border property of the element used.
// Modify a characteristic of the border for the NumNbPage element NumNbPage.Border.Thickness = 1
Remark: The characteristics of a border defined through programming can also be directly assigned to an element: // Define the border characteristics MyBorder is Border MyBorder.Color = LightRed MyBorder.Thickness = 5 Â // Borders for the NumNbPage control in the report NumNbPage.Border = MyBorder
Type of line for the border The Type property is used to define and get the type of line of the border. The available constants are as follows (caution: the effect of these constants will differ when the border is used in a report or when it is used for a cell in an Excel document). | | | | Constant | Effect in Excel | Effect in a report | Effect in dBorder | LineNone | No line. | No line. | No line. | LineSolid | | with the thickness defined in millimeters. | | LineSolidThick | | with the thickness defined in millimeters. | | LineSolidMedium | | with the thickness defined in millimeters. | | LineDouble | | with the thickness defined in millimeters. | | LineDotAndDash | | with the thickness defined in millimeters. | | LineDotAndDashMedium | | with the thickness defined in millimeters. | | LineDotAndDashDoubleDash | | with the thickness defined in millimeters. | | LineDotAndDashDoubleDashMedium | | with the thickness defined in millimeters. | | LineDotted | | with the thickness defined in millimeters | | LineDottedMedium | | with the thickness defined in millimeters | | LineDash | | with the thickness defined in millimeters. | | LineDashMedium | | with the thickness defined in millimeters. | |
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|