Spread Windows Forms 17
GrapeCity.Spreadsheet Assembly / GrapeCity.Drawing Namespace / IDrawingSurface Interface / DrawRectangle Method
The brush with which to fill the rectangle. This is optional, and can be null. If the brush is null, no fill is drawn.
The pen with which to stroke the rectangle. This is optional, and can be null. If the pen is null, no stroke is drawn.
The rectangle to draw.


In This Topic
    DrawRectangle Method
    In This Topic
    Draws a rectangle with the specified Brush and Pen. The pen and the brush can be null.
    Syntax
    'Declaration
     
    
    Sub DrawRectangle( _
       ByVal brush As Brush, _
       ByVal pen As Pen, _
       ByVal rect As Rectangle _
    ) 
    'Usage
     
    
    Dim instance As IDrawingSurface
    Dim brush As Brush
    Dim pen As Pen
    Dim rect As Rectangle
     
    instance.DrawRectangle(brush, pen, rect)
    void DrawRectangle( 
       Brush brush,
       Pen pen,
       Rectangle rect
    )

    Parameters

    brush
    The brush with which to fill the rectangle. This is optional, and can be null. If the brush is null, no fill is drawn.
    pen
    The pen with which to stroke the rectangle. This is optional, and can be null. If the pen is null, no stroke is drawn.
    rect
    The rectangle to draw.
    See Also