Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 30
Default I need to scan a column

I need to scan a column on a second page and look for a name, then scan
another column on the second page and check for how many months it has been
(less than)and if the criteria is met to add the totals in another column
from the second page and put it in a cell on the first page.

So, for example I am on page1 abd I need to look on page2 in A1 - A100 for a
name, when it finds the name I need to look on page2 b1-B100 for less than 6
months old and when it is found to add the totals on page2 c1-c100 and out
the total into cell a1 on page 1.

Hope this make sense. Thank you in advance.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default I need to scan a column

I'm assuming page1 and page2 mean Sheet1 and Sheet2.

look on page2 b1-B100 for less than 6 months old


Assuming that B1:B100 contain numbers like 1, 2, 3, etc

=SUMPRODUCT(--(Sheet2!A1:A100="name"),--(Sheet2!B1:B100<""),--(Sheet2!B1:B100<6),Sheet2!C1:C100)

If there will not be any empty cells within the range Sheet2!B1:B100 then
you can eliminate one of the arrays:

=SUMPRODUCT(--(Sheet2!A1:A100="name"),--(Sheet2!B1:B100<6),Sheet2!C1:C100)

Empty cells evaluate as 0 and 0 is <6.

--
Biff
Microsoft Excel MVP


"Vercingetorix.XIII" wrote in
message ...
I need to scan a column on a second page and look for a name, then scan
another column on the second page and check for how many months it has
been
(less than)and if the criteria is met to add the totals in another column
from the second page and put it in a cell on the first page.

So, for example I am on page1 abd I need to look on page2 in A1 - A100 for
a
name, when it finds the name I need to look on page2 b1-B100 for less than
6
months old and when it is found to add the totals on page2 c1-c100 and out
the total into cell a1 on page 1.

Hope this make sense. Thank you in advance.



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 257
Default I need to scan a column

Bonjour, Vercingetorix (de nouveau)! I'm a little suspicious about whether
you mean what you seem to have said, so first let me rephrase it and see
whether you still agree:

If "name1" is in page2!$A$1:$A$100
and "name2" is in page2!$B$1:$B$100
then SUM(page2!$C$!:$C$100)

Is that right? Because I gotta wonder whether you don't mean you want to
sum ONLY the items in col C that belong to the right name1 and/2 name2. But
if the above is what you really want, then it's pretty simple:

IF(OR(ISERROR(MATCH("name1",page2!$A$1:$A$100,0)), ISERROR(MATCH("name2",page2!$B$1:$B$100)),0,SUM(pa ge2!$C$!:$C$100))

Breaking that down into pieces:

IF(
OR(
ISERROR(
MATCH("name1",page2!$A$1:$A$100,0)
),
ISERROR(
MATCH("name2",page2!$B$1:$B$100,0)
),
0,
SUM(page2!$C$!:$C$100))

MATCH returns either a (relative) line number where the name was found, or
#N/A; therefore ISERROR(MATCH...) returns TRUE if the name was not found,
FALSE if it was. OR(ISERROR(),ISERROR()) returns TRUE if either MATCH
failed, FALSE if both succeeded (ie both names were found). So
IF(OR(...),0,SUM(...)) gives you a 0 in this cell if either name was not
found, or the sum of the whole col C if both were there. Is that really what
you wanted?

--- "Vercingetorix.XIII" wrote:
I need to scan a column on a second page and look for a name, then scan
another column on the second page and check for how many months it has been
(less than)and if the criteria is met to add the totals in another column
from the second page and put it in a cell on the first page.

So, for example I am on page1 abd I need to look on page2 in A1 - A100 for a
name, when it finds the name I need to look on page2 b1-B100 for less than 6
months old and when it is found to add the totals on page2 c1-c100 and out
the total into cell a1 on page 1.

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 30
Default I need to scan a column

Bonjour Bob,
I need to be on sheet one, where I have a list of names and have a formula
that goes to sheet 2, looks in A1:100 for the name, checks column B1:100 and
looks to see how many months it has been and (if less than 6) it will check
column C1:C100 and adds the totals for that name that is less than 6 months
old and brings them all over to Column B next to the Name it was searching
for. Thanks Bob, as always...

"Bob Bridges" wrote:

Bonjour, Vercingetorix (de nouveau)! I'm a little suspicious about whether
you mean what you seem to have said, so first let me rephrase it and see
whether you still agree:

If "name1" is in page2!$A$1:$A$100
and "name2" is in page2!$B$1:$B$100
then SUM(page2!$C$!:$C$100)

Is that right? Because I gotta wonder whether you don't mean you want to
sum ONLY the items in col C that belong to the right name1 and/2 name2. But
if the above is what you really want, then it's pretty simple:

IF(OR(ISERROR(MATCH("name1",page2!$A$1:$A$100,0)), ISERROR(MATCH("name2",page2!$B$1:$B$100)),0,SUM(pa ge2!$C$!:$C$100))

Breaking that down into pieces:

IF(
OR(
ISERROR(
MATCH("name1",page2!$A$1:$A$100,0)
),
ISERROR(
MATCH("name2",page2!$B$1:$B$100,0)
),
0,
SUM(page2!$C$!:$C$100))

MATCH returns either a (relative) line number where the name was found, or
#N/A; therefore ISERROR(MATCH...) returns TRUE if the name was not found,
FALSE if it was. OR(ISERROR(),ISERROR()) returns TRUE if either MATCH
failed, FALSE if both succeeded (ie both names were found). So
IF(OR(...),0,SUM(...)) gives you a 0 in this cell if either name was not
found, or the sum of the whole col C if both were there. Is that really what
you wanted?

--- "Vercingetorix.XIII" wrote:
I need to scan a column on a second page and look for a name, then scan
another column on the second page and check for how many months it has been
(less than)and if the criteria is met to add the totals in another column
from the second page and put it in a cell on the first page.

So, for example I am on page1 abd I need to look on page2 in A1 - A100 for a
name, when it finds the name I need to look on page2 b1-B100 for less than 6
months old and when it is found to add the totals on page2 c1-c100 and out
the total into cell a1 on page 1.

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 30
Default I need to scan a column

Yes T, The first formulas worked beautifully, thank you......

"T. Valko" wrote:

I'm assuming page1 and page2 mean Sheet1 and Sheet2.

look on page2 b1-B100 for less than 6 months old


Assuming that B1:B100 contain numbers like 1, 2, 3, etc

=SUMPRODUCT(--(Sheet2!A1:A100="name"),--(Sheet2!B1:B100<""),--(Sheet2!B1:B100<6),Sheet2!C1:C100)

If there will not be any empty cells within the range Sheet2!B1:B100 then
you can eliminate one of the arrays:

=SUMPRODUCT(--(Sheet2!A1:A100="name"),--(Sheet2!B1:B100<6),Sheet2!C1:C100)

Empty cells evaluate as 0 and 0 is <6.

--
Biff
Microsoft Excel MVP


"Vercingetorix.XIII" wrote in
message ...
I need to scan a column on a second page and look for a name, then scan
another column on the second page and check for how many months it has
been
(less than)and if the criteria is met to add the totals in another column
from the second page and put it in a cell on the first page.

So, for example I am on page1 abd I need to look on page2 in A1 - A100 for
a
name, when it finds the name I need to look on page2 b1-B100 for less than
6
months old and when it is found to add the totals on page2 c1-c100 and out
the total into cell a1 on page 1.

Hope this make sense. Thank you in advance.






  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 30
Default I need to scan a column


Bob, email me, I have a ? for you. Ill try using the email here but usually
it wont work. Thanks
"Bob Bridges" wrote:

Bonjour, Vercingetorix (de nouveau)! I'm a little suspicious about whether
you mean what you seem to have said, so first let me rephrase it and see
whether you still agree:

If "name1" is in page2!$A$1:$A$100
and "name2" is in page2!$B$1:$B$100
then SUM(page2!$C$!:$C$100)

Is that right? Because I gotta wonder whether you don't mean you want to
sum ONLY the items in col C that belong to the right name1 and/2 name2. But
if the above is what you really want, then it's pretty simple:

IF(OR(ISERROR(MATCH("name1",page2!$A$1:$A$100,0)), ISERROR(MATCH("name2",page2!$B$1:$B$100)),0,SUM(pa ge2!$C$!:$C$100))

Breaking that down into pieces:

IF(
OR(
ISERROR(
MATCH("name1",page2!$A$1:$A$100,0)
),
ISERROR(
MATCH("name2",page2!$B$1:$B$100,0)
),
0,
SUM(page2!$C$!:$C$100))

MATCH returns either a (relative) line number where the name was found, or
#N/A; therefore ISERROR(MATCH...) returns TRUE if the name was not found,
FALSE if it was. OR(ISERROR(),ISERROR()) returns TRUE if either MATCH
failed, FALSE if both succeeded (ie both names were found). So
IF(OR(...),0,SUM(...)) gives you a 0 in this cell if either name was not
found, or the sum of the whole col C if both were there. Is that really what
you wanted?

--- "Vercingetorix.XIII" wrote:
I need to scan a column on a second page and look for a name, then scan
another column on the second page and check for how many months it has been
(less than)and if the criteria is met to add the totals in another column
from the second page and put it in a cell on the first page.

So, for example I am on page1 abd I need to look on page2 in A1 - A100 for a
name, when it finds the name I need to look on page2 b1-B100 for less than 6
months old and when it is found to add the totals on page2 c1-c100 and out
the total into cell a1 on page 1.

  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default I need to scan a column

You're welcome. Thanks for the feedback!

--
Biff
Microsoft Excel MVP


"Vercingetorix.XIII" wrote in
message ...
Yes T, The first formulas worked beautifully, thank you......

"T. Valko" wrote:

I'm assuming page1 and page2 mean Sheet1 and Sheet2.

look on page2 b1-B100 for less than 6 months old


Assuming that B1:B100 contain numbers like 1, 2, 3, etc

=SUMPRODUCT(--(Sheet2!A1:A100="name"),--(Sheet2!B1:B100<""),--(Sheet2!B1:B100<6),Sheet2!C1:C100)

If there will not be any empty cells within the range Sheet2!B1:B100 then
you can eliminate one of the arrays:

=SUMPRODUCT(--(Sheet2!A1:A100="name"),--(Sheet2!B1:B100<6),Sheet2!C1:C100)

Empty cells evaluate as 0 and 0 is <6.

--
Biff
Microsoft Excel MVP


"Vercingetorix.XIII" wrote
in
message ...
I need to scan a column on a second page and look for a name, then scan
another column on the second page and check for how many months it has
been
(less than)and if the criteria is met to add the totals in another
column
from the second page and put it in a cell on the first page.

So, for example I am on page1 abd I need to look on page2 in A1 - A100
for
a
name, when it finds the name I need to look on page2 b1-B100 for less
than
6
months old and when it is found to add the totals on page2 c1-c100 and
out
the total into cell a1 on page 1.

Hope this make sense. Thank you in advance.






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
Scan column for first of a list Chip Excel Discussion (Misc queries) 1 May 24th 08 05:19 PM
Virus scan Gren Excel Discussion (Misc queries) 2 October 26th 07 03:31 PM
how do i scan documents T Nickel Setting up and Configuration of Excel 1 September 4th 07 03:58 PM
Scan and remove column data query IE Excel Discussion (Misc queries) 5 March 23rd 07 09:50 AM
Scan and remove column data query IE Excel Worksheet Functions 5 March 23rd 07 09:50 AM


All times are GMT +1. The time now is 11:25 AM.

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

About Us

"It's about Microsoft Excel"