How do I conditionally format a cell so if not blank it is grey?
I tried to do 'not equal', but it didn't work.
I am using Windows Office 2003 with Windows XP at work. I don't see the same feature as below:
What I have tried so far:
Edit: Figured what was wrong. In my production (actual work Excel), they were filled with white color. It wasn't my Excel file, so I was not aware of this before.
Does this work for you:
You find this dialog on the Home ribbon, under the Styles group, the Conditional Formatting menu, New rule....
You can use Conditional formatting with the option "Formula Is". One possible formula is
=NOT(ISBLANK($B1))
Another possible formula is
=$B1<>""
In Excel 2003 you should be able to create a formatting rule like:
=A1<>"" and then drag/copy this to other cells as needed.
If that doesn't work, try =Len(A1)>0.
If there may be spaces in the cell which you will consider blank, then do:
=Len(Trim(A1))>0
Let me know if you can't get any of these to work. I have an old machine running XP and Office 2003, I can fire it up to troubleshoot if needed.
This worked for me:
=NOT(ISBLANK(A1))
I wanted a box around NOT Blank cells in an entire worksheet.
Use the $A1 if you want the WHOLE ROW formatted based on the A1, B1, etc result.
Thanks!
This method works for Excel 2016, and calculates on cell value, so can be used on formula arrays (i.e. it will ignore blank cells that contain a formula).
Highlight the range.
Home > Conditional Formatting > New Rule > Use a Formula.
Enter "=LEN(#)>0" (where '#' is the upper-left-most cell in your range).
Alter the formatting to suit your preference.
Note: Len(#)>0 be altered to only select cell values above a certain length.
Note 2: '#' must not be an absolute reference (i.e. shouldn't contain '$').
An equivalent result, "other things being equal", would be to format all cells grey and then use Go To Special to select the blank cells prior to removing their grey highlighting.
Related
My conditional formatting rules I am using to highlight a row with value = 1 dont seem to be working because there is an existing formula in the cell. So I assume excel is seeing the formula but not the actual value and not highlighting it. Is there a way around this? I tried =$A2=VALUE(1) and it highlighted some rows but no the correct one.
You can do this by going to Conditional Formatting -> Rules to Highlight Cells -> Equals. Then, you enter 1 and select the preferred formatting.
I hope that I translated the menu correctly; I use Excel in the German language since it's my mothertongue.
On a brand new Excel file, I want to use commandButton_click to see if any of the numbers are ouside my tolerance (example +/- 0.0005)
IF any of the numbers are outside the tolerance, it should highlight the "wrong" cells (see picture).
Update: If someone know how I can do that in Conditional Formatting please show me. Thank you very much!
With conditional formatting you would do it as follows:
Select the cells in the range A6:O7
Click Home > Conditional Formatting > New Rule.
In the New Formatting Rule dialog box, click Use a formula to determine which cells to format.
Under Format values where this formula is true, type the formula: =ABS(A6-A1)>$D$4 (make sure the reference $D$4 corresponds to where you have the tolerance input).
Click Format, and then choose the formatting options you want to apply to values which are outside the tolerance.
Click OK on all open dialogs.
You don't need the command button with this solution, as Excel will apply the formatting immediately. Just take care not to paste formatting, because then you will destroy the above configured conditional formatting. So only paste values.
This is a slight variation of #trincot 's idea. You can create a named range which stands for tolerance and then use that for greater readability. Note that you have to do this twice, once for the upper cells and once for the lower cells:
If you haven't used named ranges before, select the two cells (A4:B4 in the screenshot) which contain the tolerance and click Create Names from Selection on the Formulas tab.
I am stumped at what should be a simple matter. I have this formula in a column of cells:
=IF(ISBLANK(BG7),"",IF(BG7>=70,"OverBought",IF(BG7<=30,"Oversold","Neutral")))
The formula works and the cell shows the correct word.
I would like to apply conditional formatting to the result of the formula
green for Oversold
red for OverBought
yellow for Neutral
I have tried every variation I can think of for "Value of Cell" with and without quotes, "Enter a Formula" etc and no dice. What am I missing?
I used your formula, selected the cells, and used the menu "Conditional Format", then first option (something like "highlight cells"), then forth option ("equal"), then typed Oversold with no quotes and anything else, then selected a format option.
Then i repeated the same steps for the other values (Neutral, OverBought), selecting different format options.
It worked.
This set of rules work for me:
Go to Conditional Formatting > New Rule > Format only cells that contain > Cell value Equal to Whatever.
Admittedly I use Excel 2013, not 2010 as in your case, but I'd be very surprised if there is much difference for conditional formatting rules like these.
I am using a Substitute Formula to replace a character '?' with '#'. But the formula isnt working as desired for the other rows when i drag the formula downwards.
The same output gets copied for others rows too. This happens even though the formula for other cells corresponds to its respective cells.
Please help!!!
Your formula is fine; it works correctly for me.
I can replicate your behaviour by setting the spreadsheet to manual calculation, so my thought is that yours is too.
You can check the setting from the Formula tab on the Ribbon. Click the Calculation Options item to see the current setting.
If it is manual, change to Automatic and your formulae should work as expected.
I have a condition set up =IF(C2<42,C4="") the background color will turn red if met.
When dragging the crosshair (at the bottom left of the cell) to neighbouring cells, the formula stays the same.
I need the formula to then change to =IF(D2<42,D4="") and so on 300+ times, Is there any way to refer to the current column i.e =IF(thiscolumn-row2 < 42, thiscolum-row4 = "")
Excel sometimes by default puts dollar signs in front of the cell/row labels
(ie $C$4 instead of C4 .... the dollar signs tell excel not to change the formula with each row but to lock in the original values. Does your rule in conditional formatting show dollar signs? That may be your problem. Get rid of the dollar signs and what you need should work.
You don't use If in Conditional Formatting formulas. The formula itself defines the condition that you are looking for, so the if is already implied. So your formula should simply be something like:
=C2<42
I'm confused about the 2nd part of your formula, C4="". Is that supposed to be a 2nd condition? If so, use an AND statement:
=AND(C2<42,C4="")
If you are using Excel 2007 or 2010 another source of potential confusion is that references don't change in the Conditional Formatting formula box when you drag them around, even if they are relative.
Assuming you want to apply formatting to the range c1:d300, select that range of cells, bring up the conditional formatting box and enter:
=AND(C2<42,C4="")
Now it will apply the formatting with relative references to the full selected range.