ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   how to autopopulate a cell using a formula (https://www.excelbanter.com/excel-discussion-misc-queries/224245-how-autopopulate-cell-using-formula.html)

Abby

how to autopopulate a cell using a formula
 
i am trying to create a formula to allow the cell to autopopulate a category.
For example
If I type "yellow" in B1 I want "BASIC" to appear in A1
If I type "green" in B2 I want "PRIMARY" to appear in A2

Luke M

how to autopopulate a cell using a formula
 
Try looking up the VLOOKUP function in the XL help file. You'll need to
create a table somewhere (say, D2:E10), listing your associations, but then
your final formula should look something like
=VLOOKUP(B1,$D$2:$E$10,2,FALSE)

You could then copy this down the A column as desired.
--
Best Regards,

Luke M
*Remember to click "yes" if this post helped you!*


"ABBY" wrote:

i am trying to create a formula to allow the cell to autopopulate a category.
For example
If I type "yellow" in B1 I want "BASIC" to appear in A1
If I type "green" in B2 I want "PRIMARY" to appear in A2


Russ_Hiatt[_2_]

how to autopopulate a cell using a formula
 
in cell A1 place an if statement (=IF(B1="yellow","BASIC","Why Not
Yellow?"))but thats will only show basic if its yellow and not for any other
color. If they dont say "yellow" then "why Not Yellow" will be in A1. you can
do the same for A2 just with different wording.

"ABBY" wrote:

i am trying to create a formula to allow the cell to autopopulate a category.
For example
If I type "yellow" in B1 I want "BASIC" to appear in A1
If I type "green" in B2 I want "PRIMARY" to appear in A2


Abby

how to autopopulate a cell using a formula
 
if i want to say Yellow and green would be basic would the formula be

=IF(B1="yellow,green","BASIC","Why Not Yellow?")

"Russ_Hiatt" wrote:

in cell A1 place an if statement (=IF(B1="yellow","BASIC","Why Not
Yellow?"))but thats will only show basic if its yellow and not for any other
color. If they dont say "yellow" then "why Not Yellow" will be in A1. you can
do the same for A2 just with different wording.

"ABBY" wrote:

i am trying to create a formula to allow the cell to autopopulate a category.
For example
If I type "yellow" in B1 I want "BASIC" to appear in A1
If I type "green" in B2 I want "PRIMARY" to appear in A2


Fred Smith[_4_]

how to autopopulate a cell using a formula
 
No. It would be:

=if(and(b1="yellow",b2="green"),"BASIC","Other than Basic")

Regards,
Fred.

"ABBY" wrote in message
...
if i want to say Yellow and green would be basic would the formula be

=IF(B1="yellow,green","BASIC","Why Not Yellow?")

"Russ_Hiatt" wrote:

in cell A1 place an if statement (=IF(B1="yellow","BASIC","Why Not
Yellow?"))but thats will only show basic if its yellow and not for any
other
color. If they dont say "yellow" then "why Not Yellow" will be in A1. you
can
do the same for A2 just with different wording.

"ABBY" wrote:

i am trying to create a formula to allow the cell to autopopulate a
category.
For example
If I type "yellow" in B1 I want "BASIC" to appear in A1
If I type "green" in B2 I want "PRIMARY" to appear in A2



Abby

how to autopopulate a cell using a formula
 
That formula doesn't work. It always brings up "Other than Basic" even when
I have yellow in the field.

"Fred Smith" wrote:

No. It would be:

=if(and(b1="yellow",b2="green"),"BASIC","Other than Basic")

Regards,
Fred.

"ABBY" wrote in message
...
if i want to say Yellow and green would be basic would the formula be

=IF(B1="yellow,green","BASIC","Why Not Yellow?")

"Russ_Hiatt" wrote:

in cell A1 place an if statement (=IF(B1="yellow","BASIC","Why Not
Yellow?"))but thats will only show basic if its yellow and not for any
other
color. If they dont say "yellow" then "why Not Yellow" will be in A1. you
can
do the same for A2 just with different wording.

"ABBY" wrote:

i am trying to create a formula to allow the cell to autopopulate a
category.
For example
If I type "yellow" in B1 I want "BASIC" to appear in A1
If I type "green" in B2 I want "PRIMARY" to appear in A2




Ross

how to autopopulate a cell using a formula
 
Seems like Luke's suggestion of a Vlookup would be the best, but you could
also try:
=if(b1="yellow","basic", if(b1="green", "primary","the alternative"))
Put if into b1 and copy down??
--
smither fan


"ABBY" wrote:

i am trying to create a formula to allow the cell to autopopulate a category.
For example
If I type "yellow" in B1 I want "BASIC" to appear in A1
If I type "green" in B2 I want "PRIMARY" to appear in A2


Chris Bode[_21_]

how to autopopulate a cell using a formula
 

you can achieve this task using vlookup
in sheet2 enter data as
A1 B1
yellow Basic
green Primary
Now in sheet1, select A1 and enter formula
=VLOOKUP(B1,Sheet2!$A$1:$B$2,2,FALSE)

Chris
------
Convert your Excel spreadsheet into an online calculator.
http://www.spreadsheetconverter.com




--
Chris Bode

Ross

how to autopopulate a cell using a formula
 
Oops. Mean't to say put it into A1 and copy down.
--
smither fan


"Ross" wrote:

Seems like Luke's suggestion of a Vlookup would be the best, but you could
also try:
=if(b1="yellow","basic", if(b1="green", "primary","the alternative"))
Put if into b1 and copy down??
--
smither fan


"ABBY" wrote:

i am trying to create a formula to allow the cell to autopopulate a category.
For example
If I type "yellow" in B1 I want "BASIC" to appear in A1
If I type "green" in B2 I want "PRIMARY" to appear in A2


Ross

how to autopopulate a cell using a formula
 
Try another:
=IF(OR(B1="yellow",B1="green"),"basic","primary")
--
smither fan


"ABBY" wrote:

i am trying to create a formula to allow the cell to autopopulate a category.
For example
If I type "yellow" in B1 I want "BASIC" to appear in A1
If I type "green" in B2 I want "PRIMARY" to appear in A2


Dave Peterson

how to autopopulate a cell using a formula
 
You have to have Yellow in B1 AND at the same time Green in B2.

If you have both those values in those cells and you don't get BASIC, you could
be in manual calculation mode.

In xl2003 menus:
Tools|Options|Calculation tab
change it to automatic

If you're in automatic mode, then you don't have yellow and green (exactly) in
those cells. Maybe you have extra spaces in the cells????

I'd retype them and see what happens.

ABBY wrote:

That formula doesn't work. It always brings up "Other than Basic" even when
I have yellow in the field.

"Fred Smith" wrote:

No. It would be:

=if(and(b1="yellow",b2="green"),"BASIC","Other than Basic")

Regards,
Fred.

"ABBY" wrote in message
...
if i want to say Yellow and green would be basic would the formula be

=IF(B1="yellow,green","BASIC","Why Not Yellow?")

"Russ_Hiatt" wrote:

in cell A1 place an if statement (=IF(B1="yellow","BASIC","Why Not
Yellow?"))but thats will only show basic if its yellow and not for any
other
color. If they dont say "yellow" then "why Not Yellow" will be in A1. you
can
do the same for A2 just with different wording.

"ABBY" wrote:

i am trying to create a formula to allow the cell to autopopulate a
category.
For example
If I type "yellow" in B1 I want "BASIC" to appear in A1
If I type "green" in B2 I want "PRIMARY" to appear in A2




--

Dave Peterson


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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com