#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,670
Default How to use Index?

Does anyone have any suggestions on how to locate a value from a list?
The given list of numbers under column A
1,3,5,7,11,13,17,19,23
If I enter an integer 15 in cell B2, then it will return 17 in cell B1 and
13 in cell B3.
If I enter an integer 13 in cell B2, then it will return 13 in cell B1 and
13 in cell B3, since the list contains the number of 13
Does anyone have any suggestions?
Thanks in advance for any suggestions
Eric
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,651
Default How to use Index?

On Thu, 4 Oct 2007 17:52:01 -0700, Eric wrote:

Does anyone have any suggestions on how to locate a value from a list?
The given list of numbers under column A
1,3,5,7,11,13,17,19,23
If I enter an integer 15 in cell B2, then it will return 17 in cell B1 and
13 in cell B3.
If I enter an integer 13 in cell B2, then it will return 13 in cell B1 and
13 in cell B3, since the list contains the number of 13
Does anyone have any suggestions?
Thanks in advance for any suggestions
Eric


B1: =INDEX(A1:A9,MATCH(B2,A1:A9,1))
B3: =INDEX(A1:A9,MATCH(B2,A1:A9,1)+1*(COUNTIF(A1:A9,B2 )<1))


--ron
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
Chart axes color index vs font color index [email protected] Charts and Charting in Excel 4 December 7th 06 04:05 PM
Index ( ) Epinn New Users to Excel 4 September 5th 06 06:52 AM
How do I pull the col. index value as well as row index value Vikram Dhemare Excel Discussion (Misc queries) 1 March 29th 06 07:48 AM
Index? HJ Excel Discussion (Misc queries) 8 February 9th 06 04:29 PM
Index needs a little help Reignman Excel Worksheet Functions 1 July 7th 05 03:54 AM


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