Problem with IF condition

ChrisSingle

New Member
Joined
Jun 17, 2011
Messages
3
Hi,<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:eek:ffice:eek:ffice" /><o:p></o:p>
<o:p></o:p>
I am trying to write an IF condition in excel, but somehow don’t seem to manage to get it to work. <o:p></o:p>
I want Cell C37 to automatically fill its content depending on the choice in Cell B37, which has a drop down menu with “setting off from”, “arrive at” and “collect from” (B38, B39 and B40). <o:p></o:p>
If “setting off from” then the content of C35 should move to C37<o:p></o:p>
If “arrive at” or “collect from” then the content of G35 should move to C37<o:p></o:p>
<o:p></o:p>
I have written<o:p></o:p>
=IF(B37="setting off from";C37=C35;IF(B37=”arrive at”;C37=G35;IF(B37=”collect from”;C37=G35;"false")))<o:p></o:p>
<o:p></o:p>
But not sure why its not working<o:p></o:p>
<o:p></o:p>
Many thanks in advance for your help<o:p></o:p>
<o:p></o:p>

Chris Single
 

Excel Facts

Can you AutoAverage in Excel?
There is a drop-down next to the AutoSum symbol. Open the drop-down to choose AVERAGE, COUNT, MAX, or MIN
If I understand correctly you're using the formula in the cell C37, in that case you don't need to put C37=C35 only C35
So the formula is:
=IF(B37="setting off from";C35;IF(B37=”arrive at”;G35;IF(B37=”collect from”;G35;"false")))

Assuming that's what you're doing.
 
Upvote 0
=IF(B37="setting off from",C35,IF(OR(B37={"arrive at","collect from"}),G35))
 
Upvote 0
Try this:
=IF(B37="setting off from",C35,IF(B37="arrive at",G35,IF(B37="collect from",G35,FALSE)))

I think this will get you what you are looking for.
 
Upvote 0

Forum statistics

Threads
1,214,646
Messages
6,120,718
Members
448,986
Latest member
andreguerra

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
Back
Top