[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.ILabelOptions

ILabelOptions Interface

Indicates the cell label options.

Use this interface to configure how a watermark label is displayed for a range, including its position, visibility, font, foreground color, and margin. You can access these options from LabelOptions and use LabelAlignment and LabelVisibility to control the label layout. SpreadJS only.

Namespace: GrapeCity.Documents.Excel
Assembly: DS.Documents.Excel.dll
Syntax
public interface ILabelOptions
Public Interface ILabelOptions
Examples
worksheet.Range["A1"].Value = "Name";
worksheet.Range["A1"].Watermark = "Required";
ILabelOptions labelOptions = worksheet.Range["A1"].LabelOptions;
labelOptions.Alignment = LabelAlignment.topLeft;
labelOptions.Visibility = LabelVisibility.visible;

Properties

Name Description
Alignment

Gets or sets the cell label position.

This property controls where the watermark label is displayed within the cell. The value is one of the LabelAlignment constants. If no position has been set, this property returns topLeft. SpreadJS only.

Font

Gets the font used by the watermark label.

Use the returned font object to configure the watermark label font for the range, such as its bold style, italic style, size, and color. SpreadJS only.

ForeColor

Gets or sets the color of the watermark in the range.

This property applies the foreground color to the watermark label for the range. SpreadJS only.

Margin

Gets or sets the margin of the watermark label for the range.

Visibility

Gets or sets whether the watermark is shown in the padding area, the cell area, or automatically based on the cell value.

Use visible to always show the watermark in the padding area, hidden to show it in the cell area based on the cell value, or auto to switch between the two behaviors automatically. If no visibility has been set, this property returns auto. SpreadJS only.