Conditional Formatting to highlight first cell in a row that is not null

kat517

New Member
Joined
Oct 3, 2023
Messages
5
Office Version
  1. 365
Platform
  1. Windows
I am trying to create a conditional formatting rule to highlight the first cell in the row with a value (or that is not blank/null). See below. See below - I would like the formula to populate as noted below. The spreadsheet is trying to list projects by weeks and hours. I would like each project to highlight the first cell in which there are hours.

I have looked for solutions online, and found a solution for a similar request but in columns, but I tried to replicate with no luck.

1696357777741.png
 

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.
Select Range from B2:I4 and use following formula to conditional format. Try it and revert

Excel Formula:
=And(A1="",B2<>"")
 
Upvote 0
What version of Excel are you using?

I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)

How about
Excel Formula:
=countifs($b2:b2,"<>")=1
 
Upvote 0
What version of Excel are you using?

I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)

How about
Excel Formula:
=countifs($b2:b2,"<>")=1

I'm on Microsoft 365.

Unfortunately that formula highlights the first cell in each row instead of the first cell with a value.

1696359320658.png
 
Upvote 0
Select Range from B2:I4 and use following formula to conditional format. Try it and revert

Excel Formula:
=And(A1="",B2<>"")

Hi - thanks, but using that formula did not highlight anything. I tried =AND(B2="",C2<>"") but that highlights the cells in each row before the cell with the value (see below).
1696359556776.png
 
Upvote 0
Do you have a formula in those cells that returns ""
 
Upvote 0
Do you have a formula in those cells that returns ""
Yes, the cells have a formula calculating hours/week but returns "" if the project falls outside of those dates. I tried to simplify the view for the thread, without realizing that might be critical info! Sorry about that.

Below is the file showing the formula in cell F3 which is used for columns F+.

1696360732332.png
 
Upvote 0
Ok, how about
Excel Formula:
=COUNTIFS($F3:F3,">0")=1
 
Upvote 1
Solution
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,223,230
Messages
6,170,883
Members
452,364
Latest member
springate

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top