+ Reply to Thread
Results 1 to 7 of 7

convert a negative number to a positive number by adding 49

  1. #1
    Forum Contributor
    Join Date
    09-25-2011
    Location
    Lenasia, Johannesburg,South Africa
    MS-Off Ver
    Excel 2019
    Posts
    269

    convert a negative number to a positive number by adding 49

    Hi

    I need some help with a formula to do some calculations for me


    I have a set of six numbers that are recorded in a worksheet that I am attching

    I would like each number to be subtracted by 25

    The next I would like to take the value and if its a negative one to add 49 to it

    Iff the first number after subtracting is 0 , 49 should be added to it


    Thank you in anticipation

    Raj
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    03-23-2004
    Location
    London, England
    MS-Off Ver
    Excel 2019
    Posts
    7,064

    Re: convert a negative number to a positive number by adding 49

    Not entirely clear whether you are adding 49 to all the numbers or just the first one.
    Try this

    in P3
    =IF(B3<25,B3+24,B3-25)
    copy to other cells if required
    Regards
    Special-K

    Ensure you describe your problem clearly, I have little time available to solve these problems and do not appreciate numerous changes to them.

  3. #3
    Forum Contributor
    Join Date
    09-25-2011
    Location
    Lenasia, Johannesburg,South Africa
    MS-Off Ver
    Excel 2019
    Posts
    269

    Re: convert a negative number to a positive number by adding 49

    Hi

    Thank you for your help so kind of you.

    I think I have not really made my self very clear.

    I have a set of 6 numbers from a lotto results.
    To each of these numbers I need to subtract 25 and get a value. The result will be positive or negative .

    If the value is 0 after subtraction , 49 should replace the zero

    So I will in turn now get 6 new sets of numbers in the the row.

    my third row should look at each number in the second set and if the value is a negative one example -19, 49 must be added to this number to get a positive value.

    so if my first set is 6 25 3 45 27 13 after subtracting 25 will be -19 0 -22 20 2 -12 the sero must be replaced by 40
    the third set if the number is negative 49 must be added to it -19+49 = 30 49 27 (-22+49) 20 2 37(-12+49)

    I trust that this may help with solving my issue

    Thanking you in anticipation

    Raj
    49

  4. #4
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,209

    Re: convert a negative number to a positive number by adding 49

    Third set

    =IF(B3<=25,B3+24,B3-25)

    as per Special-K

    OR

    =IF(I3<=0,I3+49,I3)

  5. #5
    Forum Expert boopathiraja's Avatar
    Join Date
    07-12-2013
    Location
    Coimbatore,TamilNadu, India
    MS-Off Ver
    Excel 2007, 2013, 2016, 365
    Posts
    1,455

    Re: convert a negative number to a positive number by adding 49

    You may try this

    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Click just below left if it helps, Boo?ath?

  6. #6
    Forum Contributor
    Join Date
    09-25-2011
    Location
    Lenasia, Johannesburg,South Africa
    MS-Off Ver
    Excel 2019
    Posts
    269

    Re: convert a negative number to a positive number by adding 49

    Hi

    Thank you Special-K John Topley and boonpathiraja for the help

    Its working brilliantly

  7. #7
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,939

    Re: convert a negative number to a positive number by adding 49

    khanaran welcome to the forum

    How goes it there in SA, goed ek hoop? (SA ex-pat here from PE and Klerksdorp)

    Please update your profile as necessary to properly reflect the exact version(s) of Excel your question relates to. Members tailor answers based on your Excel version. Your profile says 2003, but your file indicates at least 2007
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 3
    Last Post: 03-10-2016, 04:40 PM
  2. Replies: 9
    Last Post: 02-04-2016, 01:18 AM
  3. Adding negative number = positive in another cell.
    By agm89 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 12-02-2014, 03:12 AM
  4. Carrying Over Negative number to next column as a positive number
    By Redraven in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 08-21-2014, 06:39 AM
  5. Move Negative Number and Change to a Positive Number
    By Alvin Hunter in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 02-04-2013, 08:36 PM
  6. Replies: 2
    Last Post: 11-13-2008, 12:35 AM
  7. Adding a positive and a negative number
    By jzatrotary in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 08-03-2007, 06:36 PM

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