appropriate function

  • Thread starter Thread starter rekoop
  • Start date Start date
R

rekoop

Is there a function that will read the value in one cell
and place a corresponding value in the cell the function
is located?
i.e. cell A1 contains the name of a city. A hoped for
function in Cell B1 would read the value in A1 and place
population drawn from another location (i.e. sheet 2).
The would allow for the populations to be changed outside
of the function.
As different city names are listed down column A the
corresponding populations are read into the cell in
column B.
I was thinking of an if statement but all the variables
would have to be cell references.

I hope this makes sense and thank-you for any suggestions.
 
Hi,

If you have the City name & population listed in Column A & B
respectively(for eg) in Sheet 2,
use this formula in cell B1 of Sheet 1 and copy it down as required.

=VLOOKUP(A1,Sheet2!A:B,2,FALSE)

Regards

Govind.
 
=VLOOKUP(A1,Sheet2!$A$1:$B$100,2,FALSE)

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
Back
Top