CELL function. Get various information about the cell.(Microsoft Excel)
Retrieve various information such as the format and lock status of the specified cell.
This function is not available online.
How it works
=CELL(info_type,reference)
Argument | Omission | Explanation |
---|---|---|
info_type | Required argument. Details to follow. | |
reference | Target cell. |
info_type
address
Gets the top-left address of the range of cells specified.
The result is an absolute reference.
col
Retrieves the top-left-most column number of a given cell range.
However, the COLUMN function is better.
color
If it is a negative number, it is set to 1 if the format changes the character color, otherwise it is set to 0.
contents
Returns the value of a cell.
There is no need to use this function.
filename
The location where the file was saved and the sheet name of the target cell.
If not saved in a file, it will be blank.
format
Returns the set format.
Returns a specific code.
Format | Result |
---|---|
General | G |
0 | F0 |
#,##0 | ,0 |
0.00 | F2 |
#,##0.00 | ,2 |
$#,##0_);($#,##0) | C0 |
$#,##0_);[red]($#,##0) | C0- |
$#,##0.00_);($#,##0.00) | C2 |
$#,##0.00_);[red]($#,##0.00) | C2- |
0% | P0 |
0.00% | P2 |
0.00E+00 | S2 |
# ?/? # ??/?? | G |
m/d/yy m/d/yy h:mm mm/dd/yy | D4 |
d-mmm-yy dd-mmm-yy | D1 |
d-mmm dd-mmm | D2 |
mmm-yy | D3 |
mm/dd | D5 |
h:mm AM/PM | D7 |
h:mm:ss AM/PM | D6 |
h:mm | D9 |
h:mm:ss | D8 |
parentheses
The result is 1 if the cell is formatted with positive values or all values enclosed in parentheses (), or 0 if the cell is not formatted.
It is not often used.
protect
If the cell is locked, the value is "1"; otherwise, it is "0".
row
Retrieves the top-left-most row number of a given cell range.
However, the COLUMN function is better.
type
The type of input value.
Type | Result |
---|---|
Blank | b |
Text | l |
Others | v |
The following functions are better: ISBLANK, ISTEXT, ISNUMBER, ISLOGICAL.
width
Gets how many characters wide the cell is in standard font.
---
Discussion
New Comments
No comments yet. Be the first one!