ITabRegion.BorderStyle

Syntax

BorderStyle: TabBorderStyle;

Description

The BorderStyle property determines region border line type.

Comments

To determine region border color, use the ITabRegion.BorderColor property.

Example

Executing the example requires that the repository contains a regular report with connected unit. The connected unit and the EventsClass class must be specified as event handler.

Add links to the Drawing, Report, Tab system assemblies.

Class EventsClass: ReportEvents
    
Public Sub OnAfterRecalcSheet(Sheet: IPrxSheet);
    
Var
        
        Tab: ITabSheet;
        Reg: ITabRegion;
    
Begin
        
// Get report sheet table
        Tab := Sheet.Table;
        
// Add a region to collection
        Reg := Tab.Regions.Add;
        
// Determine table range where region is located
        Reg.Range := Tab.Cells(1133);
        
// Set background color of table region
        Reg.BackgroundColor := New GxColor.CreateARGB(6425500);
        
// Set border color of table region
        Reg.BorderColor := New GxColor.CreateRGB(25500);
        
// Set line type of table region border
        Reg.BorderStyle := TabBorderStyle.Double;
        
// Set line width of table region border
        Reg.BorderWeight := TabBorderWeight.Hairline;
        
// Set visibility of table region
        Reg.Visible := True;
        
// Add the second region to collection
        Reg := Tab.Regions.Add;
        
// Determine the second table range where region is located
        Reg.Range := Tab.Cells(2244);
        
// Set formatting of the second table region
        Reg.BackgroundColor := New GxColor.CreateARGB(6400255);
        Reg.BorderColor := 
New GxColor.CreateRGB(00255);
        Reg.Visible := 
True;
    
End Sub OnAfterRecalcSheet;
End Class EventsClass;

After executing the example, on report update two regions will be selected that will have different colors and different borders.

See also:

ITabRegion