XmlMappedRange.FormulaLabel Property
Gets or sets the formula label type for the XmlMappedRange control.
Namespace: Microsoft.Office.Tools.Excel
Assembly: Microsoft.Office.Tools.Excel (in Microsoft.Office.Tools.Excel.dll)
Syntax
'Declaration
Property FormulaLabel As XlFormulaLabel
XlFormulaLabel FormulaLabel { get; set; }
Property Value
Type: XlFormulaLabel
The formula label type for the XmlMappedRange control.
Remarks
The return value of this property can be xlNone if the range contains no labels, or one of the following XlFormulaLabel constants:
Examples
The following code example uses the FormulaLabel property to set an XmlMappedRange to be a column label. This code example assumes that the current worksheet contains an XmlMappedRange named CustomerLastNameCell.
Private Sub ShowFormulaLabel()
Globals.ThisWorkbook.AcceptLabelsInFormulas = True
Me.CustomerLastNameCell.FormulaLabel = _
Excel.XlFormulaLabel.xlColumnLabels
End Sub
private void ShowFormulaLabel()
{
Globals.ThisWorkbook.AcceptLabelsInFormulas = true;
this.CustomerLastNameCell.FormulaLabel =
Excel.XlFormulaLabel.xlColumnLabels;
}
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.