i'm hitting a wall! how do i force an action?

cdchambers

New Member
Joined
Feb 4, 2005
Messages
4
i'm not even sure if you can do this, but i'm new to excel so it's possible this is really easier than I am making it.

In A1, if the Answer is "yes" - jump to cell C1.
In A1, if the answer is "NO" - jump to cell D1.

If that is not possible, is it possible to do this -

In A1, if answer is "Yes" - highlight cell c1
in a1, if answer is "No" - highlight cell d1.

BEST CASE ANSWER - COMBINE BOTH !!!!!

thanks for help! (GO EAGLES!!)

~Catherine
 

Some videos you may like

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.

rs2k

Well-known Member
Joined
Aug 15, 2004
Messages
1,413
Catherine, welcome to the board,
The second part of your question is do-able - Conditional formating.

In cell C1
Format|Conditional format - choose "formula is" =IF(A1="Yes",TRUE,FALSE) then pick your format, the same goes for D1 (change yes to no)

or, do you mean highlight the cell to become active?

Colin.
 

cdchambers

New Member
Joined
Feb 4, 2005
Messages
4
thanks for responding

what i want is for the cell to become a color, such as yellow, to alert the person filling in the form to go to the highlighted cell.

So in a1, if the answer is yes, I want c1 to become yellow. if in a1 the answer is no, i want d1 to become yellow.

does that make sense?
 

Tazguy37

MrExcel MVP
Joined
May 28, 2004
Messages
4,237
Both could be done...I'm thinking with some VBA code. As far as I know (though, there could be a way) you can't jump to another cell depending on the results of a formula. I've been wrong before, however....

Anyway, as rs2k said, one answer to your problem would involve conditional formatting. You can set it up like this:

Go to cell C1, and from the Format menu, select Conditional Formatting. Select Formula Is from the dropdown, and enter the following formula: =UPPER(A1)="YES"
Choose a format and hit OK.

Likewise, in D1, and use this formula: =UPPER(A1)="NO"
Choose a format and hit OK.

I used the UPPER function just in case the user enters "yes" or "Yes" or "YES," you will get the same results. Hope that helps! Post back if you need more help or if you'd like to see a VBA code solution. (Just thought I'd throw that out there, conditional formatting should do just fine.)
 

HalfAce

MrExcel MVP
Joined
Apr 6, 2003
Messages
9,454
Only because it's what was asked for first...
(And only if the value(s) yes or no in A1 are not the results of a formula...)
You could right click the sheet tab, choose view code and paste this in the white area on the right. (Then press AltQ to close the VB Editor).
Now when either yes or no gets entered into A1, C1 or D1 (respectively) will get selected.


<font face=Courier New><SPAN style="color:#00007F">Private</SPAN> <SPAN style="color:#00007F">Sub</SPAN> Worksheet_Change(<SPAN style="color:#00007F">ByVal</SPAN> Target <SPAN style="color:#00007F">As</SPAN> Range)
<SPAN style="color:#00007F">If</SPAN> Target.Address <> "$A$1" <SPAN style="color:#00007F">Then</SPAN> <SPAN style="color:#00007F">Exit</SPAN> <SPAN style="color:#00007F">Sub</SPAN>
<SPAN style="color:#00007F">If</SPAN> [A1] = "" <SPAN style="color:#00007F">Or</SPAN> Target.Count > 1 <SPAN style="color:#00007F">Then</SPAN> <SPAN style="color:#00007F">Exit</SPAN> <SPAN style="color:#00007F">Sub</SPAN>
<SPAN style="color:#00007F">If</SPAN> UCase(Target.Value) = "YES" <SPAN style="color:#00007F">Then</SPAN> [C1].Select
<SPAN style="color:#00007F">If</SPAN> UCase(Target.Value) = "NO" <SPAN style="color:#00007F">Then</SPAN> [D1].Select
<SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">Sub</SPAN></FONT>


(If A1 is in fact the return of a formula, post back. We can get around that too.)

Hope it helps,
Dan
 

Watch MrExcel Video

Forum statistics

Threads
1,122,561
Messages
5,596,853
Members
414,107
Latest member
Tigretto

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top