GrapeCity MultiRow Windows Forms Documentation
AllCornerRadius Property
Example 


Gets or sets the radius for all corners.
Syntax
<RefreshPropertiesAttribute(RefreshProperties.All)>
Public Property AllCornerRadius As Single
Dim instance As RoundedBorder
Dim value As Single
 
instance.AllCornerRadius = value
 
value = instance.AllCornerRadius
[RefreshProperties(RefreshProperties.All)]
public float AllCornerRadius {get; set;}

Property Value

A System.Single value that indicates the radius for all corners if they are the same; otherwise, returns -1. The value can be 0f to 0.5f.
Exceptions
ExceptionDescription
System.ArgumentOutOfRangeExceptionThe value is less than 0f or more than 0.5f.
Example
The following code example shows how to set the AllCornerRadius that sets the same radius for all the corners. This example is part of a larger example available for the Border class.
void setRoundedBorderToCell_Click(object sender, EventArgs e)
        {
            Template template1 = gcMultiRow1.Template;
            Row row = template1.Row;

            //Use this constructor to set the outline RoundedBorder
            RoundedBorder roundedBorder1 = new RoundedBorder();
            roundedBorder1.Outline = new Line(LineStyle.MediumDashed, Color.Orange);
            roundedBorder1.AllCornerRadius = 0.3f;
            row.Cells[0].Style.Border = roundedBorder1;

            // Reload template1.
            this.gcMultiRow1.Template = template1;
        }
Private Sub setRoundedBorderToCell_Click(ByVal sender As Object, ByVal e As EventArgs) Handles 
setRoundedBorderToCell.Click
        Dim template1 As Template = gcMultiRow1.Template
        Dim row As Row = template1.Row

        'Use this constructor to set the outline RoundedBorder
        Dim roundedBorder1 As New RoundedBorder()
        roundedBorder1.Outline = New Line(LineStyle.MediumDashed, Color.Orange)
        roundedBorder1.AllCornerRadius = 0.3F
        row.Cells(0).Style.Border = roundedBorder1

        ' Reload template1.
        Me.gcMultiRow1.Template = template1
    End Sub
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

RoundedBorder Class
RoundedBorder Members
TopLeftCornerRadius Property
TopRightCornerRadius Property
BottomLeftCornerRadius Property
BottomRightCornerRadius Property

 

 


Copyright © GrapeCity, inc. All rights reserved.