#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4
Default countif question

Hi

I am using the COUNTIF formula in a spreadsheet but i am struggling with a
part of it.

Column C has start times and column D has finish times. In row 1 from column
P to KR is 24 hour clock at 5 minute intervals. Column O has names.

This is my formula at present which works.

=COUNTIF($C3:$D3,P$1:KR$1)

This only highlights the start time and finish time. I also want to
highlight the time inbetween the start and finish time.

I hope i explained this well enough for you to help.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4
Default countif question



I have now found out that 2003 excel does not go from P to KR range in the
COUNTIF formula so I am now guessing that i need to use some other
formula........


Help!!
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4
Default countif question

Hi

Thanks for your reply. The formula works great for what i need.


Thankyou for your help.


"stokie123" wrote:



I have now found out that 2003 excel does not go from P to KR range in the
COUNTIF formula so I am now guessing that i need to use some other
formula........


Help!!

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,203
Default countif question

I'm a bit confused as to what your goal is. You mention highlighting cells,
but which cells are you wanting to highlight?

Are you wanting to highlight the cells on the same row with a start time &
end time & name underneath the columns (P:KR) where the times in row 1
'overlap' the start and end times (columns C:D)?

If this is the case, then you could put this formula in P3:
=IF(AND(P$1=$C3,P$1<=$D3),1,0)
and fill it out to the right to the end and then set conditional formatting
of those cells to become highlighted when their value = 1.

Hope this helps some.

"stokie123" wrote:

Hi

I am using the COUNTIF formula in a spreadsheet but i am struggling with a
part of it.

Column C has start times and column D has finish times. In row 1 from column
P to KR is 24 hour clock at 5 minute intervals. Column O has names.

This is my formula at present which works.

=COUNTIF($C3:$D3,P$1:KR$1)

This only highlights the start time and finish time. I also want to
highlight the time inbetween the start and finish time.

I hope i explained this well enough for you to help.

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4
Default countif question

Hi,

I have another question if you can help.

=IF(AND(P$1=$C3,P$1<=$D3),1,0) works great but i need it to ignore blank
cells. It is returning a value of 1 for blank cells.

how do I get it to do that?

"JLatham" wrote:

I'm a bit confused as to what your goal is. You mention highlighting cells,
but which cells are you wanting to highlight?

Are you wanting to highlight the cells on the same row with a start time &
end time & name underneath the columns (P:KR) where the times in row 1
'overlap' the start and end times (columns C:D)?

If this is the case, then you could put this formula in P3:
=IF(AND(P$1=$C3,P$1<=$D3),1,0)
and fill it out to the right to the end and then set conditional formatting
of those cells to become highlighted when their value = 1.

Hope this helps some.

"stokie123" wrote:

Hi

I am using the COUNTIF formula in a spreadsheet but i am struggling with a
part of it.

Column C has start times and column D has finish times. In row 1 from column
P to KR is 24 hour clock at 5 minute intervals. Column O has names.

This is my formula at present which works.

=COUNTIF($C3:$D3,P$1:KR$1)

This only highlights the start time and finish time. I also want to
highlight the time inbetween the start and finish time.

I hope i explained this well enough for you to help.



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,203
Default countif question

I think what you need is this:
=IF(ISBLANK(P$1),0,IF(AND(P$1=$C3,P$1<=$D3),1,0))

Since I only got a 1 when values in row 1 were blank/missing and not when
values in C or D were missing.



"stokie123" wrote:

Hi,

I have another question if you can help.

=IF(AND(P$1=$C3,P$1<=$D3),1,0) works great but i need it to ignore blank
cells. It is returning a value of 1 for blank cells.

how do I get it to do that?

"JLatham" wrote:

I'm a bit confused as to what your goal is. You mention highlighting cells,
but which cells are you wanting to highlight?

Are you wanting to highlight the cells on the same row with a start time &
end time & name underneath the columns (P:KR) where the times in row 1
'overlap' the start and end times (columns C:D)?

If this is the case, then you could put this formula in P3:
=IF(AND(P$1=$C3,P$1<=$D3),1,0)
and fill it out to the right to the end and then set conditional formatting
of those cells to become highlighted when their value = 1.

Hope this helps some.

"stokie123" wrote:

Hi

I am using the COUNTIF formula in a spreadsheet but i am struggling with a
part of it.

Column C has start times and column D has finish times. In row 1 from column
P to KR is 24 hour clock at 5 minute intervals. Column O has names.

This is my formula at present which works.

=COUNTIF($C3:$D3,P$1:KR$1)

This only highlights the start time and finish time. I also want to
highlight the time inbetween the start and finish time.

I hope i explained this well enough for you to help.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Countif question mtaystl11 Excel Worksheet Functions 7 June 23rd 06 07:29 PM
CountIF Question guile Excel Worksheet Functions 1 January 26th 06 02:43 AM
COUNTIF Question zbert Excel Worksheet Functions 1 November 1st 04 01:59 AM
COUNTIF Question zbert Excel Worksheet Functions 0 October 31st 04 06:02 PM
COUNTIF Question zbert Excel Worksheet Functions 2 October 31st 04 05:14 PM


All times are GMT +1. The time now is 07:16 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"