Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 349
Default Compare Cell

Hi, I am trying to compare a cell that contains text located at "m87" with a
list of place names, ie Brisbane, Sydney, Melbourne.

Each city has numbers to go with it, so if the cell contains say Brisbane,
then it would input 30 into cell "n88". The same for the rest with diffrent
numbers of course.

I searched the forums for something similar, but no luck.

Any help appreciated.
Peter
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Compare Cell


Here's something that could work for you, its a VLOOKUP formul

+-------------------------------------------------------------------
|Filename: Vlookup.zip
|Download: http://www.excelforum.com/attachment.php?postid=4631
+-------------------------------------------------------------------

--
davesexce

-----------------------------------------------------------------------
davesexcel's Profile: http://www.excelforum.com/member.php...fo&userid=3170
View this thread: http://www.excelforum.com/showthread.php?threadid=53292

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default Compare Cell

$n n88
=if(m87="","",vlookup(m87,Sheet2!$A$1:$B$3,2,0))

assume on sheet2 in A1:B3:
Brisbane 30
Sydney 40
Melbourne 50

--
Regards,
Tom Ogilvy


"Peter" wrote:

Hi, I am trying to compare a cell that contains text located at "m87" with a
list of place names, ie Brisbane, Sydney, Melbourne.

Each city has numbers to go with it, so if the cell contains say Brisbane,
then it would input 30 into cell "n88". The same for the rest with diffrent
numbers of course.

I searched the forums for something similar, but no luck.

Any help appreciated.
Peter

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 349
Default Compare Cell

Thanks to you both.
My mindset is still that everything has to be done in VBA, good to see it
can be done just as well in a formula =)
Now I have a new set of things to learn...this Vlookup thing looks
interesting.

Peter

"Tom Ogilvy" wrote:

$n n88
=if(m87="","",vlookup(m87,Sheet2!$A$1:$B$3,2,0))

assume on sheet2 in A1:B3:
Brisbane 30
Sydney 40
Melbourne 50

--
Regards,
Tom Ogilvy


"Peter" wrote:

Hi, I am trying to compare a cell that contains text located at "m87" with a
list of place names, ie Brisbane, Sydney, Melbourne.

Each city has numbers to go with it, so if the cell contains say Brisbane,
then it would input 30 into cell "n88". The same for the rest with diffrent
numbers of course.

I searched the forums for something similar, but no luck.

Any help appreciated.
Peter

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
FIND / SEARCH text compare cell to string in 3rd cell nastech Excel Discussion (Misc queries) 0 October 29th 07 02:51 AM
Compare text string of a cell in Column A VS another cell in Colum Tan New Users to Excel 2 August 1st 07 09:45 AM
Compare text string of a cell in Column A VS another cell in Colum Tan Excel Discussion (Misc queries) 1 August 1st 07 09:03 AM
Compare text string of a cell in Column A VS another cell in Colum Tan Excel Worksheet Functions 1 August 1st 07 09:01 AM
How do I compare cells and if FALSE compare to next cell in EXCEL Cindie Excel Worksheet Functions 0 March 24th 06 05:29 PM


All times are GMT +1. The time now is 02:58 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"