#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 14
Default Function problem

1=Apple, 2=Car,3=Ship

when I input "1" in A1,then will prompt "Apple" in B2
How to do it, thanks
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 89
Default Function problem

Hi Winnie,

Use VLookup.

Make a lookup table in the same worksheet or in another. Do it like this:

In cell F1 type 1 and in cell G1 type Apple
In cell F2 type 2 and in cell G2 type Car
In cell F3 type 3 and in cell G3 type Ship

Name the range F1:G3 .... any name. "Thinggies" will do.


Now in Cell B2 type the formula =VLookup(A1,Thinggies,2)

When you input "1" in A1, B2 should find the reference in the table and
display "apple" for you. The number 2 in the above VLookup formula specifies
the column to find the needed data. Follow the same pattern for car and ship.

If you look up "Vlookup" in Excel help it will give you more info about that
function. There is also HLookup which does the same thing at 90 degrees (ie
horizontally instead of vertically)

.... and take enough apples. Sounds like you'll go thru a few on this trip!

LOL Keith




"Winnie" wrote:

1=Apple, 2=Car,3=Ship

when I input "1" in A1,then will prompt "Apple" in B2
How to do it, thanks

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default Function problem

Since this is looking for an exact match, I think I'd add that 4th argument:

=VLookup(A1,Thinggies,2,False)



Kevryl wrote:

Hi Winnie,

Use VLookup.

Make a lookup table in the same worksheet or in another. Do it like this:

In cell F1 type 1 and in cell G1 type Apple
In cell F2 type 2 and in cell G2 type Car
In cell F3 type 3 and in cell G3 type Ship

Name the range F1:G3 .... any name. "Thinggies" will do.

Now in Cell B2 type the formula =VLookup(A1,Thinggies,2)

When you input "1" in A1, B2 should find the reference in the table and
display "apple" for you. The number 2 in the above VLookup formula specifies
the column to find the needed data. Follow the same pattern for car and ship.

If you look up "Vlookup" in Excel help it will give you more info about that
function. There is also HLookup which does the same thing at 90 degrees (ie
horizontally instead of vertically)

... and take enough apples. Sounds like you'll go thru a few on this trip!

LOL Keith

"Winnie" wrote:

1=Apple, 2=Car,3=Ship

when I input "1" in A1,then will prompt "Apple" in B2
How to do it, thanks


--

Dave Peterson
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
Priorsheet Function Problem David Excel Worksheet Functions 2 August 30th 06 05:38 PM
function problem regarding cell range chindo Excel Worksheet Functions 1 November 10th 05 03:06 AM
Simple function problem headly Excel Worksheet Functions 2 July 7th 05 08:50 AM
Lookup function problem (kg) greencecil Excel Worksheet Functions 3 July 1st 05 04:54 PM
Problem with function "Worksheet_Change" konpego Excel Worksheet Functions 0 June 23rd 05 05:46 AM


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