+ Reply to Thread
Results 1 to 8 of 8

Running balance into minus figures

  1. #1
    Registered User
    Join Date
    03-23-2010
    Location
    UK, North
    MS-Off Ver
    Excel 2003
    Posts
    4

    Running balance into minus figures

    Evening everyone.
    Firstly I just want to say - fantastic forum, I have found many answers here that have helped me along the years, but now I need some more specific help.

    So I am creating a running balance on a sheet in 2003 using hh:mm custom format. What I want is the cells to calculate a balance into minus figures. The positive figures show as green, the negatives as red, I used conditional formatting for this. But when the balance requires a negative figure the display is ############

    Getting a "-" to display in excel is always a bit of a pain for me, I just enter a ' before and this normally works. I had to use that technique to get the conditional formatting to work properly in this case. I was thinking of using a custom format along the lines of hh:mm;[green]0.00;[red]-0.00; but I have had a play around with that and no luck.

    This has really got me stuck and any help would be greatly appreciated as always. I have attached a draft of the workbook I am using if it helps.
    Last edited by lostreligion; 03-24-2010 at 07:10 PM.

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Running balance into minus figures

    Excel won't display negative times unless you use the 1904 date system, which is a bad idea.

    You can format negative times as, e.g., -0.0000
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Registered User
    Join Date
    03-23-2010
    Location
    UK, North
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Running balance into minus figures

    Could you suggest a possible alternative for what I am trying to get here?

    I have seen a working excel sheet that does exactly what I am trying to get at, up to minus 23:59 and positive 23:59 so I am thinking that there must be a way around it.

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Running balance into minus figures

    As I said, you can change to the 1904 date system.

    That shifts the dates in every workbook by four years, though.

  5. #5
    Registered User
    Join Date
    03-23-2010
    Location
    UK, North
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Running balance into minus figures

    I think I will give it a go, it is something I have never tried before.
    It is only for a very small project, but it will be handy for me and my colleges to keep an eye on the every increasing popularity of flexible work time in the workplace.

    Thanks a bunch, I will let you know how I get on. Your help is very much appreciated sir/madam

  6. #6
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Running balance into minus figures

    For anyone who opens the workbook without 1904 date settings, they're going to see some wacky dates. And you'll see wacky dates in everone else's.

    Have at it, but I repeat, it's not a good idea.

  7. #7
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Running balance into minus figures

    Totally agree with shg's sentiments - switching Date Systems for aesthetics is not a great move.

    Time in XL is Decimal so on the 1900 Date System you can have negative time values you just can't display them in Time Format as already outlined.

    You can dummy around it by storing values as Text strings, eg - using your file:

    F6:
    =IF($C6="","",REPT("-",E6>($G$5-SUM($E5:$E$6)))&TEXT(ABS($G$5-SUM($E$6:$E6)),"hh:mm"))
    copied down to F17

  8. #8
    Registered User
    Join Date
    03-23-2010
    Location
    UK, North
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Running balance into minus figures

    Thanks for that DonkeyOte, I think I will give that a go aswell.

    It looks like the 1904 date option has worked for what I needed, pretty much spot on so I am very pleased! I just created a little macro to revert back/forth the date systems and that seems to have solved the small issue of having to revert back.

    Thanks for the help - Topic solved

+ 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