+ Reply to Thread
Results 1 to 6 of 6

problem with if and sign

  1. #1
    Registered User
    Join Date
    02-25-2013
    Location
    greece
    MS-Off Ver
    Excel 2007
    Posts
    3

    problem with if and sign

    Hello.
    I have a problem. I try to make with <<if>> a case but i have not the correct results.

    I have this (f-d)_(e-f)_(e-g) , where e,f,d are columns, and i want the sign from inside each subtraction, in order to chech finally the result.

    Finally i want to create an case in which i will check all the three results and it will decide if the result is minus or positive.

    Thanks a lot for your help.

    Waiting for your replys.

    George.

  2. #2
    Forum Guru :) Sixthsense :)'s Avatar
    Join Date
    01-01-2012
    Location
    India>Tamilnadu>Chennai
    MS-Off Ver
    2003 To 2010
    Posts
    12,770

    Re: problem with if and sign

    Not clear what you are trying to do

    Can you please show it in excel with your data and the expected output for better understanding?

    To Attach a File:

    1. Click on Go Advanced
    2. In the frame Attach Files you will see the button Manage Attachments
    3. Click the button.
    4. A new window will open titled Manage Attachments - Excel Forum.
    5. Click the Browse... button to locate your file for uploading.
    6. This will open a new window File Upload.
    7. Once you have located the file to upload click the Open button. This window will close.
    8. You are now back in the Manage Attachments - Excel Forum window.
    9. Click the Upload button and wait until the file has uploaded.
    10. Close the window and then click Submit.


    If your problem is solved, then please mark the thread as SOLVED>>Above your first post>>Thread Tools>>
    Mark your thread as Solved


    If the suggestion helps you, then Click *below to Add Reputation

  3. #3
    Registered User
    Join Date
    02-25-2013
    Location
    greece
    MS-Off Ver
    Excel 2007
    Posts
    3

    Smile Re: problem with if and sign

    Sorry for the inconvenience and thanks again.

    I want to subtract the dates from f,d,e ang g columns [for example (f3-d3)*(e3-f3)*(e3-g3)= ?] and i only care about the result (if it is minus or positive) of each subtraction, in order to have a result not as number but only as sign (- or +).
    If i multiply the sutractions the result is not correct.

    So i do not know what to do. I think of an <<if>> with 8 cases (all the possible results of its subtraction combined), but i don't know if it is right and i don;t know how to do it.

    Thanks a lot again.

    George.
    Attached Files Attached Files

  4. #4
    Forum Guru :) Sixthsense :)'s Avatar
    Join Date
    01-01-2012
    Location
    India>Tamilnadu>Chennai
    MS-Off Ver
    2003 To 2010
    Posts
    12,770

    Re: problem with if and sign

    Sorry I am unable to understand your requirement and logic

  5. #5
    Registered User
    Join Date
    02-25-2013
    Location
    greece
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: problem with if and sign

    I WANT THIS :

    (f-d)*(e-f)*(e-g)=X
    [F-D=A, E-F=B, E-G=C] SO
    IF A=- AND B=- AND C=- THEN RESULT (X) = -
    IF A=- AND B=+ AND C=- THEN RESULT (X) = -
    IF A=- AND B=- AND C=+ THEN RESULT (X) = -
    IF A=- AND B=+ AND C=+ THEN RESULT (X) = -
    IF A=+ AND B=- AND C=- THEN RESULT (X) = -
    IF A=+ AND B=- AND C=+ THEN RESULT (X) = -
    IF A=+ AND B=+ AND C=- THEN RESULT (X) = -
    IF A=+ AND B=+ AND C=+ THEN RESULT (X) = +

    THIS IS WHAT I NEED TO DO.

    SORRY IF I CAN NOT EXPLAINE BETTER.

    THANKS A LOT FOR YOUR HELP, ONE MORE TIME

  6. #6
    Forum Expert Fotis1991's Avatar
    Join Date
    10-11-2011
    Location
    Athens(The homeland of the Democracy!). Greece
    MS-Off Ver
    Excel 1997!&2003 & 2007&2010
    Posts
    13,744

    Re: problem with if and sign

    Hi--Καλημέρα Γιώργο.

    So in your example ALL the results are - . Correct?

    In I1 and copy down.

    =IF(AND(F1-D1<0;E1-F1>0;E1-G1>0);"+";"-")

    Does this works for you?
    Regards

    Fotis.

    -This is my Greek whisper to Europe.

    --Remember, saying thanks only takes a second or two. Click the little star * below, to give some Rep if you think an answer deserves it.

    Advanced Excel Techniques: http://excelxor.com/

    --KISS(Keep it simple Stupid)

    --Bring them back.

    ---See about Acropolis of Athens.

    --Visit Greece.

+ 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