NativeExcel2 for .Net Developer's Reference

IWorkbook.ReferenceStyle Property

Gets or sets how Microsoft Excel displays cell references and row and column headings in either A1 or R1C1 reference style.

[Visual Basic]
PropertyReferenceStyleAsXlReferenceStyle
[C#]
XlReferenceStyleReferenceStyle{get;set;}
[C++]
__propertyXlReferenceStyleget_ReferenceStyle();
__propertyvoidset_ReferenceStyle(XlReferenceStyle);
[JScript]
functiongetReferenceStyle():XlReferenceStyle
functionsetReferenceStyle(XlReferenceStyle);

Property Value

One of the XlReferenceStyle values.

Example

This example sets R1C1 reference style for a workbook.

[C#]
book.ReferenceStyle = XlReferenceStyle.xlR1C1;
[VisualBasic]
book.ReferenceStyle = XlReferenceStyle.xlR1C1
[C++]
book->ReferenceStyle = XlReferenceStyle::xlR1C1;

See Also

IWorkbook Interface | NativeExcel Namespace | XlReferenceStyle Enumeration