Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
B G B G is offline
external usenet poster
 
Posts: 11
Default How do I get a cell value based on different criteria?

I have a simple template that I am trying to set up to do an analysis on our
profit for a line of business. In column A11 am using a Code (BL, EP, PB
etc) that will affect the value of the cell in column G12. Ths value is not
the same for each of the codes in A11. What "simple" formula can I use to
accomplish this. I am guessing I will need a type of validation or lookup
but don't know the proper procedures. Thanks

BG
--



  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4,339
Default How do I get a cell value based on different criteria?

VLOOKUP

In Columns A & B of say Sheet2 have your codes and their corresponding values

in G12:

=VLOOKUP(A11,Sheet2!A:B,2,false)

To allow for A11 value not present in table:

=IF(ISNA(VLOOKUP(A11,Sheet2!A:B,2,false)),"Invalid
code",VLOOKUP(A11,Sheet2!A:B,2,false))

<A11 could use Data Validation to ensure a valid list based on the codes in
your lookup table on Sheet2 and hence remove need for error check.

HTH

"B G" wrote:

I have a simple template that I am trying to set up to do an analysis on our
profit for a line of business. In column A11 am using a Code (BL, EP, PB
etc) that will affect the value of the cell in column G12. Ths value is not
the same for each of the codes in A11. What "simple" formula can I use to
accomplish this. I am guessing I will need a type of validation or lookup
but don't know the proper procedures. Thanks

BG
--



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
Help with this conditional IF statement C-Dawg Excel Discussion (Misc queries) 3 May 15th 06 06:01 PM
How do I set a cell value based on a formula in another cell? dingy101 Excel Discussion (Misc queries) 1 November 21st 05 08:51 AM
Locate a cell, based on a criteria, then use the 'Cell' command... cdavidson Excel Discussion (Misc queries) 1 November 17th 05 06:30 PM
How do I get info from a cell based on criteria from another cell paul Excel Worksheet Functions 0 October 4th 05 08:55 AM
I am trying to color fill a cell based on specific criteria jglen Excel Discussion (Misc queries) 1 May 27th 05 05:30 PM


All times are GMT +1. The time now is 03:13 PM.

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"