A worksheet in Excel (worksheet) is a two-dimensional table of rows and columns, when we create an application using Excel (such as writing VBA code), or when we create a complex Excel application (such as a formula, PivotTable report, statistical chart, and so on), You need to refer to a separate Excel cell (called a cell) or a range of cells (called a range), and it's important to know more about how each cell or range of cells is referenced and set up, which will help improve our operational habits or programming, thereby increasing our productivity.
Two kinds of cell reference methods
There are probably a lot of users who are not particularly aware that there are two types of cell references in Excel: A1 and R1C1. The former is called relative reference, which is called absolute reference. In Excel2003, we can switch cell references in the menu tools-Options-general, as shown in the following figure:
In Excel2007, click the Office icon in the upper-left corner of the main form, select Excel Options, and in the pop-up dialog box, select the Formulas tab, which has a switch to the cell reference, as shown in the following figure:
In VBA, we can switch cell references by using the following code:
Application.refrencestyle = XlA1 or XLR1C1