Syntax

expression.RecordRelative

expression A variable that represents an Application object.

Example

This example displays the address of the active cell on Sheet1 in A1 style if RecordRelative is False; otherwise, it displays the address in R1C1 style.

Visual Basic for Applications
Worksheets("Sheet1").Activate If Application.RecordRelative = False Then MsgBox ActiveCell.Address(ReferenceStyle:=xlA1) Else MsgBox ActiveCell.Address(ReferenceStyle:=xlR1C1) End If
Macros with absolute references? record Record macros with relative addresses? record relative Record Relative Property RecordRelative RecordRelative Property

See also: