Mourning the loss of our friend, WhitPhil.
There's no such thing as a stupid question, but they're the easiest to answer.
JoinTour
Login
Search
 
All Other Software
Tag Cloud
access audio blue screen boot bsod connection crash dell desktop driver drivers dvd email error excel excel 2003 firefox hard drive hardware hijackthis internet keyboard laptop malware monitor motherboard network networking outlook problem processor recovery router screen slow sound spyware tdlwsp.dll trojan upgrade vba video virus vista vundo windows windows 7 windows vista windows xp wireless
Search
Search for:
Tech Support Guy Forums > Software & Hardware > All Other Software >
Solved: Excel IF= question

Tip: Click here to scan for System Errors and Optimize PC performance
[ Sponsored Link ]

 
Thread Tools
ezpt's Avatar
Computer Specs
Junior Member with 2 posts.
 
Join Date: Nov 2009
Experience: Beginner
02-Nov-2009, 01:45 PM #1
Solved: Excel IF= question
This is what I am trying to do..

IF A7=M then use formula 'A' if not use formula 'B'.

This is how I wrote it..

=IF(E17=M,"=4.95/(AG17)-4.5)*100","=4.95/(AI17)-4.5)*100")

It did not let me use the letter so I tried it with a 1.

=IF(E17=1,"=4.95/(AG17)-4.5)*100","=4.95/(AI17)-4.5)*100")

The function works, but it enters the code (=4.95/(AG17)-4.5)*100) not activating the formula.

Is there a way to default to the formulas (A, B) and also to use an M for the IF function?
etaf's Avatar
Computer Specs
Moderator with 18,638 posts.
 
Join Date: Oct 2003
Location: Surrey, UK
Experience: Intermediate
02-Nov-2009, 01:52 PM #2
IF A7=M then use formula 'A' if not use formula 'B'.

=if( a7="M", formulaA, formulab)
etaf's Avatar
Computer Specs
Moderator with 18,638 posts.
 
Join Date: Oct 2003
Location: Surrey, UK
Experience: Intermediate
02-Nov-2009, 01:53 PM #3
Try this

=IF(E17="M",4.95/(AG17)-4.5)*100,4.95/(AI17)-4.5)*100)

I havent check - will do now

The brackets are all wrong

So what do you want to calculate first in the formula

formualA
4.95/(AG17)-4.5)*100
so you can see you have a closed backet and no open

Formula B
4.95/(AI17)-4.5)*100
same here

I assume it should be at the beginning

(4.95/(AG17)-4.5)*100

and

(4.95/(AI17)-4.5)*100

so

=If(A17="M", (4.95/(AG17)-4.5)*100, (4.95/(AI17)-4.5)*100 )
should work


OR
depending on the calc you want to do first

=If(A17="M", 4.95/((AG17)-4.5)*100, 4.95/((AI17)-4.5)*100 )
__________________
Please let us know what the final solution was to any problem posted
Link to HJT http://free.antivirus.com/hijackthis/
ETAF

Last edited by etaf : 02-Nov-2009 01:59 PM.
ezpt's Avatar
Computer Specs
Junior Member with 2 posts.
 
Join Date: Nov 2009
Experience: Beginner
03-Nov-2009, 09:24 AM #4
That was great this has been kicking my butt for a couple days. It's great that there are great minds out there willing to help. I just started using the Excel program and have been using only trial and error. I will be watching this board and library trying to learn more.

Thanks again.
etaf's Avatar
Computer Specs
Moderator with 18,638 posts.
 
Join Date: Oct 2003
Location: Surrey, UK
Experience: Intermediate
03-Nov-2009, 10:45 AM #5
if thats all OK now - you can now mark as solved - button at top of your first post

Any more questions on other excel issue - just post a new post
Reply Bookmark and Share

Smart Search

Find your solution!



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
WELCOME TO TECH SUPPORT GUY! Are you looking for the solution to your computer problem? Join our site today to ask your question -- for free! Our site is run completely by volunteers who want to help you solve your computer problems. See our Welcome Guide to get started.

Thread Tools


You Are Using:
Server ID
Advertisements do not imply our endorsement of that product or service.
All times are GMT -5. The time now is 02:44 PM.
Copyright © 1996 - 2009 TechGuy, Inc. All rights reserved.
Powered by vBulletin, Copyright © 2000 - 2009, Jelsoft Enterprises Ltd.
Powered by Cermak Technologies, Inc.