OpenOffice.org Forum at OOoForum.orgThe OpenOffice.org Forum
 
 [Home]   [FAQ]   [Search]   [Memberlist]   [Usergroups]   [Register
 [Profile]   [Log in to check your private messages]   [Log in

HLOOKUP

 
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Calc
View previous topic :: View next topic  
Author Message
Hyline
Newbie
Newbie


Joined: 24 May 2011
Posts: 1

PostPosted: Tue May 24, 2011 2:03 am    Post subject: HLOOKUP Reply with quote

I cant get HLOOKUP to work

I need to search an array, say A1:E1 for the cell containing a "y" and then return the corresponding value in the array C1:E1. My formula currently looks like this - =HLOOKUP("y";A1:E1;A3:E3;0).

Any help would be greatly appreciated.
Thanks - Andrew
Back to top
View user's profile Send private message
keme
Moderator
Moderator


Joined: 30 Aug 2004
Posts: 2910
Location: Egersund, Norway

PostPosted: Tue May 24, 2011 2:20 am    Post subject: Re: HLOOKUP Reply with quote

Hyline wrote:
I cant get HLOOKUP to work

I need to search an array, say A1:E1 for the cell containing a "y" and then return the corresponding value in the array C1:E1. My formula currently looks like this - =HLOOKUP("y";A1:E1;A3:E3;0).

Any help would be greatly appreciated.
Thanks - Andrew
Your formula uses a syntax similar to what would be used with the LOOKUP() function. HLOOKUP()/VLOOKUP()/MATCH() take a single, two dimensional range (table) containing both lookup and return values, unlike LOOKUP() which takes two vectors (lists), one for lookup and one for return value.

Try:
=HLOOKUP("y";A1:E3;3;0)
Back to top
View user's profile Send private message
ken johnson
Super User
Super User


Joined: 23 Apr 2009
Posts: 2032
Location: Sydney, Australia

PostPosted: Tue May 24, 2011 2:33 am    Post subject: Re: HLOOKUP Reply with quote

Hyline wrote:
I need to search an array, say A1:E1 for the cell containing a "y" and then return the corresponding value in the array C1:E1.

Are you sure about that C1:E1?
Also, your formula's second parameter should be a range of cells with the row to be searched for the "y" at the top and at least also the row with the corresponding return value.
The third parameter should be the position number of the row, within the second parameter range, that holds the return values.

Ken Johnson
_________________
If your problem has been solved please add "[Solved]" to the beginning of your first post title (edit button).
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Calc All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group