Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
knbsmith11
 
Posts: n/a
Default Conditional Statement Question

I need a formula for the following synario:

Column A = either AG, AP or WW
Column B = %
Column C = Amount
and I have 4500 rows of data below

What I want to do is say if column A = AG, than multiply column B by Column
C and add up all the rows that meet the criteria and put them in this cell.

Can anyone help?
  #2   Report Post  
Posted to microsoft.public.excel.misc
JE McGimpsey
 
Posts: n/a
Default Conditional Statement Question

one way:

=SUMPRODUCT(--(A1:A4500="AG"),B1:B4500,C1:C4500)

In article ,
knbsmith11 wrote:

I need a formula for the following synario:

Column A = either AG, AP or WW
Column B = %
Column C = Amount
and I have 4500 rows of data below

What I want to do is say if column A = AG, than multiply column B by Column
C and add up all the rows that meet the criteria and put them in this cell.

Can anyone help?

  #3   Report Post  
Posted to microsoft.public.excel.misc
Hans Knudsen
 
Posts: n/a
Default Conditional Statement Question

=SUMPRODUCT((A1:A4501="AG")*(B1:B4501)*(C1:C4501))

Hans


"knbsmith11" skrev i en meddelelse ...
I need a formula for the following synario:

Column A = either AG, AP or WW
Column B = %
Column C = Amount
and I have 4500 rows of data below

What I want to do is say if column A = AG, than multiply column B by Column
C and add up all the rows that meet the criteria and put them in this cell.

Can anyone help?



  #4   Report Post  
Posted to microsoft.public.excel.misc
knbsmith11
 
Posts: n/a
Default Conditional Statement Question

Thanks for the input, however its a little more complicated than that. I
actually need to multiply columns B & C in each row then add all the them.
So more like b1*c1 + b2*c2 +b3*c3 but for 4500 rows and if they all meet the
condition of A=AG.

"JE McGimpsey" wrote:

one way:

=SUMPRODUCT(--(A1:A4500="AG"),B1:B4500,C1:C4500)

In article ,
knbsmith11 wrote:

I need a formula for the following synario:

Column A = either AG, AP or WW
Column B = %
Column C = Amount
and I have 4500 rows of data below

What I want to do is say if column A = AG, than multiply column B by Column
C and add up all the rows that meet the criteria and put them in this cell.

Can anyone help?


  #5   Report Post  
Posted to microsoft.public.excel.misc
JE McGimpsey
 
Posts: n/a
Default Conditional Statement Question

Did you actually try it? Or just decide it doesn't work?

In article ,
knbsmith11 wrote:

Thanks for the input, however its a little more complicated than that. I
actually need to multiply columns B & C in each row then add all the them.
So more like b1*c1 + b2*c2 +b3*c3 but for 4500 rows and if they all meet the
condition of A=AG.



  #6   Report Post  
Posted to microsoft.public.excel.misc
knbsmith11
 
Posts: n/a
Default Conditional Statement Question

I tried it, and it gave me the wrong answer.

"JE McGimpsey" wrote:

Did you actually try it? Or just decide it doesn't work?

In article ,
knbsmith11 wrote:

Thanks for the input, however its a little more complicated than that. I
actually need to multiply columns B & C in each row then add all the them.
So more like b1*c1 + b2*c2 +b3*c3 but for 4500 rows and if they all meet the
condition of A=AG.


  #7   Report Post  
Posted to microsoft.public.excel.misc
JE McGimpsey
 
Posts: n/a
Default Conditional Statement Question

Then you need to look at your data. Perhaps you have leading or trailing
spaces in column A, or perhaps some of your numbers entered as Text.

To check the latter, try copying a blank cell, selecting your numbers,
then choosing Edit/Paste Special, selecting the Values and Add radio
buttons. This will coerce any text values to numeric.

In article ,
knbsmith11 wrote:

I tried it, and it gave me the wrong answer.

  #8   Report Post  
Posted to microsoft.public.excel.misc
knbsmith11
 
Posts: n/a
Default Conditional Statement Question

JE, thanks so much. You were correct, I had something in my formula wrong.
It works great now!!

"JE McGimpsey" wrote:

Then you need to look at your data. Perhaps you have leading or trailing
spaces in column A, or perhaps some of your numbers entered as Text.

To check the latter, try copying a blank cell, selecting your numbers,
then choosing Edit/Paste Special, selecting the Values and Add radio
buttons. This will coerce any text values to numeric.

In article ,
knbsmith11 wrote:

I tried it, and it gave me the wrong answer.


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
Conditional Worksheet Access Question RUSS Excel Worksheet Functions 0 January 10th 06 08:14 PM
Conditional formating on if statement SCOOBYDOO Excel Worksheet Functions 2 November 30th 05 06:58 PM
Conditional Statement in Charts smck Excel Worksheet Functions 2 November 12th 05 03:38 AM
Conditional Formatting Using If Statement On Opening Of Workbook Bill Foley Excel Worksheet Functions 11 October 19th 05 11:18 PM
conditional formatting question Deb Excel Discussion (Misc queries) 0 March 23rd 05 02:07 AM


All times are GMT +1. The time now is 02:21 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"