+ Reply to Thread
Results 1 to 6 of 6

if formula - need advice

Hybrid View

  1. #1
    Registered User
    Join Date
    03-10-2005
    MS-Off Ver
    Excel 2013
    Posts
    95

    if formula - need advice

    hi all,

    i need help in if function as example below

    A1 = Apple
    A2 = Apple

    B1 = if(and(A1="Apple",A2="Apple"),"fruit",...xxx..)

    in xxx i want to return whatever value in either A1 or A2 if it is not apple

    example A1 = Apple and A2 = banana...so it will return as Banana in value if false.

    thanks
    Last edited by koi; 09-25-2012 at 10:00 AM.

  2. #2
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,327

    Re: if function

    Your post does not comply with Rule 1 of our Forum RULES. Your post title should accurately and concisely describe your problem, not your anticipated solution. Use terms appropriate to a Google search. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will be addressed according to the OP's experience in the forum: If you have less than 10 posts, expect (and respond to) a request to change your thread title. If you have 10 or more posts, expect your post to be locked, so you can start a new thread with an appropriate title.
    To change a Title on your post, click EDIT then Go Advanced and change your title, if 2 days have passed ask a moderator to do it for you.

    HTH
    Regards, Jeff

  3. #3
    Forum Expert Jakobshavn's Avatar
    Join Date
    08-17-2012
    Location
    Lakehurst, NJ, USA
    MS-Off Ver
    Excel 2007
    Posts
    1,970

    Re: if function

    if A1 is Peaches and A2 is Pears, which do you want to see??
    Gary's Student

  4. #4
    Registered User
    Join Date
    03-10-2005
    MS-Off Ver
    Excel 2013
    Posts
    95

    Re: if formula - need advice

    hi Jakob,

    as per my example above..i'm using Apple as based, so in your example..let us use pears as based,

    so when A1 = Peaches and A2 = Pears...then obviously Peaches will come up

    =if(and(A1=Pears,A2=Pears),"Pears",if not true then will return to value with no Pears in it))

  5. #5
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,327

    Re: if formula - need advice

    Maybe a little more effort into that title would be appropriate. Adding "need advice" does nothing for describing your problem.

  6. #6
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,167

    Re: if formula - need advice

    Jakobshavn,

    Your post does not comply with Rule 7 of our Forum RULES. Please do not ignore Moderators' or Administrators' requests - note that this includes requests by senior members as well, if you are unclear about their request or instruction then send a private message to them asking for help. Do not post a reply to a thread where a moderator has requested an action that has not been complied with e.g Title change or Code tags...etc
    If I have helped, Don't forget to add to my reputation (click on the star below the post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
    Use code tags when posting your VBA code: [code] Your code here [/code]

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1