NativeExcel for .Net Developer's Reference

IRange.AddressMethod(Boolean)

Returns the range reference.

[Visual Basic]
FunctionAddress(_
ByValExternalAsBoolean_
)AsString
[C#]
stringAddress(
boolExternal
);
[C++]
String*Address(
boolExternal
);
[JScript]
functionAddress(
boolExternal
):String;

Parameters

External
True to return an external reference; False to return a local reference.

Return Value

Returns a string.

Example

This example returns the external reference for the used range

[C#]
string ref = book.Worksheets[1].UsedRange.Address(true);
[VisualBasic]
Dim ref As String = book.Worksheets(1).UsedRange.Address(True)
[C++]
String^ ref = book->Worksheets->Item[1]->UsedRange->Address(true);

See Also

IRange Interface | NativeExcel Namespace | IRange.Address Overload List