Learn How to Use Microsoft Excel CELL Function
In this article, you will learn how to use the Microsoft Excel CELL function and its prime function in Microsoft Excel. You will also get to know the Microsoft Excel CELL function return value and syntax with the help of some examples.
Microsoft Excel CELL Function
The main function of the Microsoft Excel CELL function is to get particular information about the cell. So, with the help of the CELL function, you can able to return the information about the specific cell in the worksheet. The information type is specified by the info type. You can use the CELL function to get the information like address or filename beside that you can have detailed information about the cell formatting.
Return Value of CELL Function
The return value will be the text value.
Syntax of CELL Function
Where the arguments:
info-type: It is the type of information to return about the reference.
reference: It is the reference from which you want to extract the information (optional).
How to Use Microsoft Excel CELL Function?
While using the CELL function, you can extract a wide range of information about the reference. The type of information to be returned is info-type and should be enclosed in double-quotes (" ").
Information Types of the Function
It returns the first cell address
in reference to the text.
It returns the column number of the first cell in reference.
returns the value 1 if the first cell in reference is formatted using color for negative values; or zero if not.
returns the value of the upper-left cell in reference. Formulas are not returned. Instead, the result of the formula is returned.
returns the file name and full path as text. If the worksheet that contains reference has not yet been saved, an empty string is returned.
returns a code that corresponds to the number format of the cell. See below for a list of number format codes. If the first cell in reference is formatted with color for values < 0, then "-" is appended to the code. If the cell is formatted with parentheses, returns "() - at the end of the code value.
returns 1 if the first cell in reference is formatted with parentheses and 0 if not.
returns a text value that corresponds to the label prefix - of the cell: a single quotation mark (') if the cell text is left-aligned, a double quotation mark (") if the cell text is right-aligned, a caret (^) if the cell text is centered text, a backslash () if the cell text is fill-aligned, and an empty string if the label prefix is anything else.
returns 1 if the first cell in reference is locked or 0 if not.
returns the row number of the first cell in reference.
returns a text value that corresponds to the type of data in the first cell in reference: "b" for blank when the cell is empty, "l" for the label if the cell contains a text constant, and "v" for value if the cell contains anything else.
returns the column width of the cell, rounded to the nearest integer. A unit of column width is equal to the width of one character in the default font size.
Check out the list of all other articles:
- Learn How to Get nth Match in Microsoft Excel
- Learn How to Find Missing Values in Microsoft Excel
- Learn How to Get nth Smallest Value With Criteria in Microsoft Excel
- Learn How to Sort by Text Length in Microsoft Excel
- Learn How to Sort by Two Columns in Microsoft Excel
- Learn How to Sort by Random in Microsoft Excel
- Learn How to Sort by One Column in Microsoft Excel
- Learn How to Sort by Custom List in Microsoft Excel