ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Count number of text values in a specific row (https://www.excelbanter.com/excel-worksheet-functions/145709-count-number-text-values-specific-row.html)

Carlee

Count number of text values in a specific row
 
Hello I have a data sheet that looks likes this:

Reading Date Site 1 Site 2 Site 3 Site 4 .....
Jun 1,2007 XP XP D XP
Jun 2, 2007 XP D D P

Question:
I want use a function that will enable the user to enter a date, and the
function will search for that date, and count the number of times the code
XP, is entered.

Can anyone help me out with my quest?
--
Carlee

Harimau

Count number of text values in a specific row
 
Count the number of "XP" in that row where the date is? Okay, assume that the
dates are in column A, and the site columns are B, C, D, E...

I would use this:

=COUNTIF(INDEX($A$100:$E$100, MATCH(date, $A:$A, 0), 1):INDEX($A$100:$E$100,
MATCH(date, $A:$A, 0), 5), "=XP")

Replace "$A$100:$E$100" with the range that contains your data... and
replace "5" in the MATCH function to the number of columns in your data range.

"date" is the reference that contains the date you want to look up.

Hope that helps.

"Carlee" wrote:

Hello I have a data sheet that looks likes this:

Reading Date Site 1 Site 2 Site 3 Site 4 .....
Jun 1,2007 XP XP D XP
Jun 2, 2007 XP D D P

Question:
I want use a function that will enable the user to enter a date, and the
function will search for that date, and count the number of times the code
XP, is entered.

Can anyone help me out with my quest?
--
Carlee


T. Valko

Count number of text values in a specific row
 
Try this:

H1 = some date

=COUNTIF(INDEX(A1:E3,MATCH(H1,A1:A3,0),),"xp")

Biff

"Carlee" wrote in message
...
Hello I have a data sheet that looks likes this:

Reading Date Site 1 Site 2 Site 3 Site 4 .....
Jun 1,2007 XP XP D XP
Jun 2, 2007 XP D D P

Question:
I want use a function that will enable the user to enter a date, and the
function will search for that date, and count the number of times the code
XP, is entered.

Can anyone help me out with my quest?
--
Carlee




Teethless mama

Count number of text values in a specific row
 
Assume date in A5:A100, Site 1,2,3,4.... in B5:Z100
A1: is the user to enter date

B1: =SUMPRODUCT((A5:A100=A1)*(B5:Z100="XP"))


"Carlee" wrote:

Hello I have a data sheet that looks likes this:

Reading Date Site 1 Site 2 Site 3 Site 4 .....
Jun 1,2007 XP XP D XP
Jun 2, 2007 XP D D P

Question:
I want use a function that will enable the user to enter a date, and the
function will search for that date, and count the number of times the code
XP, is entered.

Can anyone help me out with my quest?
--
Carlee



All times are GMT +1. The time now is 10:31 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com