Cell attributes

Each cell in the worksheet can be blank or have some content (text, number). It can also have its own formatting elements. The CELL function allows you to read the attributes of a cell, however it is not nearly as powerful as the old GET.CELL macro function. In the following text, you will learn how to read cell attributes.

The cell attribute is read using the CELL function, whose syntax is:

CELL (<code>, <address>)

You can see the meaning of the codes in the following table:



Default cell address (text).


Column number.


Row number.


Returns a score of 1 if the first reference cell is formatted using the color for negative number values, or 0 if it is not.


The value of the cell.


The path and file name.


A tag that represents the format of a number record.


If negative numbers are shown in parentheses, it returns value 1, or returns 0 if they are not.


Text that corresponds to the cell tag prefix.


If the cell is Locked it returns 1 and if it is not (Unlocked) returns 0.


Index indicating data type: B for empty cell, L for label, V for value.


The width of the cell.

That is, an example of using this feature can be seen in the picture:

The GET.CELL macro function cannot be directly applied in a formula. To use it, you need to get into Name Manager (CTRL + F3), and create a new name, where we will enter the GET.CELL function as a reference, which has the same syntax as the CELL function It has many more parameters, is described in detail on Mr.Excel’s website, and you can access the text at the following link.