Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.newusers
dan48
 
Posts: n/a
Default Hlookup in other columns

In doing a hlookup I would like returned the cell contents from the left
column and also left of that as in the example

x y z aa ab ac
1 2 3 4 5 6

hlookup(ab1,a1:dd1000, 1) = 5
but I am interested in receiving answer 4 and separetely answer 3

Dan
  #2   Report Post  
Posted to microsoft.public.excel.newusers
Ron Coderre
 
Posts: n/a
Default Hlookup in other columns

Try something like this:

hlookup(ab1,a1:dd1000, 1) = 5

for the matched item:
=INDEX(A1:DD1000,1,MATCH(AB1,A1:DD1,0))

For the item one cell to the left of the matched item:
=INDEX(A1:DD1000,1,MATCH(AB1,A1:DD1,0)-1)

For the item two cells to the left of the matched item:
=INDEX(A1:DD1000,1,MATCH(AB1,A1:DD1,0)-2)


Does that help?

***********
Regards,
Ron

XL2002, WinXP-Pro


"dan48" wrote:

In doing a hlookup I would like returned the cell contents from the left
column and also left of that as in the example

x y z aa ab ac
1 2 3 4 5 6

hlookup(ab1,a1:dd1000, 1) = 5
but I am interested in receiving answer 4 and separetely answer 3

Dan

  #3   Report Post  
Posted to microsoft.public.excel.newusers
dan
 
Posts: n/a
Default Hlookup in other columns

Your formula workes very well. Thank you for your help
Dan

"Ron Coderre" wrote:

Try something like this:

hlookup(ab1,a1:dd1000, 1) = 5

for the matched item:
=INDEX(A1:DD1000,1,MATCH(AB1,A1:DD1,0))

For the item one cell to the left of the matched item:
=INDEX(A1:DD1000,1,MATCH(AB1,A1:DD1,0)-1)

For the item two cells to the left of the matched item:
=INDEX(A1:DD1000,1,MATCH(AB1,A1:DD1,0)-2)


Does that help?

***********
Regards,
Ron

XL2002, WinXP-Pro


"dan48" wrote:

In doing a hlookup I would like returned the cell contents from the left
column and also left of that as in the example

x y z aa ab ac
1 2 3 4 5 6

hlookup(ab1,a1:dd1000, 1) = 5
but I am interested in receiving answer 4 and separetely answer 3

Dan

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
How to see columns from which values were not returned by HLOOKUP functions? Dmitry Kopnichev Excel Worksheet Functions 1 October 14th 05 12:04 AM
How to swap rows and columns? [email protected] Excel Discussion (Misc queries) 5 September 21st 05 08:07 AM
Hiding columns and custom views problem Bettergains Excel Discussion (Misc queries) 2 April 12th 05 11:48 PM
Removing Near-Duplicate Rows, Leaving Those w/Most Data in Specific Columns foofoo Excel Discussion (Misc queries) 1 April 2nd 05 12:02 AM
Counting the Contents of Two Columns Molochi Excel Discussion (Misc queries) 6 December 22nd 04 09:13 PM


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