[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.Forms.IControlCollection.AddLabel

AddLabel Method

AddLabel(double, double, double, double)

Adds a new ILabel.

Use this method to place a label control on the worksheet by specifying its position and size.

Declaration
ILabel AddLabel(double left, double top, double width, double height)
Function AddLabel(left As Double, top As Double, width As Double, height As Double) As ILabel
Parameters
Type Name Description
double left

The distance between the left edge of the worksheet and the label.

double top

The distance between the top edge of the worksheet and the label.

double width

The width of the label.

double height

The height of the label.

Returns
Type Description
ILabel

The newly added label control.

Examples
ILabel label = worksheet.Controls.AddLabel(20, 20, 100, 24);
label.Text = "Resolution";