+ Reply to Thread
Results 1 to 20 of 20

Excel Memory Use & File Size

  1. #1
    Valued Forum Contributor
    Join Date
    08-22-2011
    Location
    Auckland
    MS-Off Ver
    Excel 2019
    Posts
    716

    Excel Memory Use & File Size

    Hi people.. I'm using Excel 2010, I have a workbook with 5 sheets. They have some formatting. The problem sheet is the helper sheet. It has about 30 columns with formulas. I was going to have some of the formulas go to the end of the sheet, but abandoned that idea when it started crashing. That one sheet alone is over 20mb, it has minor cell background colour formatting in the columns with formulas to make it easier to read. Is it normal for excel to consume so much space?
    When trying to do anything with it now, Excel complains there's not enough memory. I've got 4gb. Is that normal?
    It's driving me nuts. It's the sort of thing you expect with freebie software, not from the biggest software company. Especially as they made the operating system too.
    Any Ideas what's causing it?
    Thanks

  2. #2
    Forum Expert teylyn's Avatar
    Join Date
    10-28-2008
    Location
    New Zealand
    MS-Off Ver
    Excel 365 Insider Fast
    Posts
    11,372

    Re: Excel Memory Use & File Size

    Hello Phil,

    Excel 2010 has over 1 million rows. With 30 columns of formulas going down to the end of the sheet, that would be 30 million formulas.

    What are these formulas? If any of them are volatile, i.e. re-calculating whenever any cell in the workbook changes, then I'm not surprised that the file crashes.

    Also, even with very short formulas, 30 million of them will tally up to quite substantial file size.

    I don't think that Excel or Microsoft are to blame, but rather poor spreadsheet design. If you can share some of what you are trying to achieve, and what formulas you are using to achieve it, then we may come up with more efficient suggestions.

    cheers,
    Last edited by teylyn; 10-30-2011 at 06:17 AM.

  3. #3
    Valued Forum Contributor
    Join Date
    08-22-2011
    Location
    Auckland
    MS-Off Ver
    Excel 2019
    Posts
    716

    Re: Excel Memory Use & File Size

    Hi teylyn.. I found that by open & repairing the file, copying sheets to another book & opening them in their own books was the way to find which sheet was causing the grief. With the helper sheet I found by deleting all the cells from 50000 to the bottom of the sheet, it brought the file size down to 8 mb. It still takes a little while to open. Not the make a cup of coffee time the whole book takes. Basically I think the workbook's stuffed now. I've tried opening it via open & repair, extract the data & recover the formulas, deleting the cells, rows & columns in the helper sheet. It bleats about a lack of memory & wont save without Excel crashing. I think I'm going to have to do & lot of copying & pasting to make another workbook. What makes it worse, I had done a backup this afternoon while the file was behaving. I tried opening that & it spat the dummy again.
    What's the point in a million rows if you can't use them. You cant use keyboard shortcuts to fill the formula to the bottom without it crashing. Yep MS get the blame.
    I was/am a user of OpenOffice for years. I gave Excel a bash because the help here & the internet in general is really good. I've learned heaps.Especially macros. OO macros are a nightmare to try & learn. Next to no information.

  4. #4
    Forum Expert teylyn's Avatar
    Join Date
    10-28-2008
    Location
    New Zealand
    MS-Off Ver
    Excel 365 Insider Fast
    Posts
    11,372

    Re: Excel Memory Use & File Size

    What's the point in a million rows if you can't use them
    You can, just make sure you do so wisely. There is never a need to pre-fill a formula down to rows that don't have any data to be processed. This is just bad practice.

    There are better ways to achieve the same thing.

  5. #5
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: Excel Memory Use & File Size

    Users complained about requiring more sheets & columns so MS obliged.

    They are available but you need to use them wisely - don't have any unused formulas, explore the Table feature
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  6. #6
    Valued Forum Contributor
    Join Date
    08-22-2011
    Location
    Auckland
    MS-Off Ver
    Excel 2019
    Posts
    716

    Re: Excel Memory Use & File Size

    Well now the situation has been forced on me lol. I've got no choice but to find a better way. The reason I was trying to use all of the column, was to make sure the friend of mine & my wife who are going to be using it, will never run out of space. He's the reason I tried excel too, office came with his laptop.
    I will explore the tables feature, you never know, I might learn some more I haven't got a clue how to use them

  7. #7
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Excel Memory Use & File Size

    if you could type into that much space it would take a long time, say you typed martin into a cell that would take say 2 seconds thats 24 days of continuous entry!
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  8. #8
    Valued Forum Contributor
    Join Date
    08-22-2011
    Location
    Auckland
    MS-Off Ver
    Excel 2019
    Posts
    716

    Re: Excel Memory Use & File Size

    Quote Originally Posted by martindwilson View Post
    if you could type into that much space it would take a long time, say you typed martin into a cell that would take say 2 seconds thats 24 days of continuous entry!
    Going on that theory, if I typed Phil in, it should take about 16. But with my keyboard skills more like 32.

    I've had a search & it looks like the memory thing is a pretty common problem. Maybe they're all trying to do what I did.

    I've looked at tables. I couldn't see a way of making that work for my purpose. I think I'd better not drag the formulas too far down.
    I've just worked out that with the average amount of data that is likely to be entered, it would take 19 years to use 10000 rows. That's 2 entries per day, 5 days a week. I reckon I could halve the amount of rows with no problems.
    Thanks for the replies

  9. #9
    Forum Expert teylyn's Avatar
    Join Date
    10-28-2008
    Location
    New Zealand
    MS-Off Ver
    Excel 365 Insider Fast
    Posts
    11,372

    Re: Excel Memory Use & File Size

    Or, you could post a sample workbook that represents your project's data structure and let us help you to do it properly without pre-filling hundreds of rows with formulas.

  10. #10
    Valued Forum Contributor
    Join Date
    08-22-2011
    Location
    Auckland
    MS-Off Ver
    Excel 2019
    Posts
    716

    Re: Excel Memory Use & File Size

    I'll do that if I can. I'm trying to resurrect the file. There's one column that keeps making excel crash. I'll persevere

  11. #11
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,238

    Re: Excel Memory Use & File Size

    Have you had a look at using a database? They tend to be geared to more data, you can then pull queries into excel for summary reports etc.

  12. #12
    Valued Forum Contributor
    Join Date
    08-22-2011
    Location
    Auckland
    MS-Off Ver
    Excel 2019
    Posts
    716

    Re: Excel Memory Use & File Size

    Quote Originally Posted by Kyle123 View Post
    Have you had a look at using a database? They tend to be geared to more data, you can then pull queries into excel for summary reports etc.
    It has crossed my mind. But you can fit what I know about databases on a pin head lol

  13. #13
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    365 Win 11
    Posts
    7,238

    Re: Excel Memory Use & File Size

    I think maybe it's time to learn...

    I've stolen this from DaveGugg's sig, but it's a great starting point http://www.deeptraining.com/litwin/d...aseDesign.aspx

  14. #14
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,457

    Re: Excel Memory Use & File Size

    @Philb1: the other option, if you're OK with a VBA solution is a Worksheet Change event monitoring the input columns and populating the formulae on a row whenever any data is entered in the row.

    That would be relatively straightforward to implement.

    In terms of making some progress, you could provide an "empty" workbook with the formulae that you use in the calculated cells together with the structure of the workbook/worksheet(s)

    Regards
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  15. #15
    Valued Forum Contributor
    Join Date
    08-22-2011
    Location
    Auckland
    MS-Off Ver
    Excel 2019
    Posts
    716

    Re: Excel Memory Use & File Size

    Quote Originally Posted by TMShucks View Post
    @Philb1: the other option, if you're OK with a VBA solution is a Worksheet Change event monitoring the input columns and populating the formulae on a row whenever any data is entered in the row.
    That's something I've thought about too. I don't know how to do it though. There are a few macros in the workbook, I tried removing them to see if they were the cause. They're not. I managed to clear that problem column, I had to do it a couple of hundred cells at a time. 50000 in all lol. There's still something corrupting it because when I try to save it, it either takes an eternity or it crashes.
    This all appears to have come from saving 10 columns to the bottom of the sheet. Just as well it wasn't more. Does this qualify as a valuable lesson ?
    As soon as I've got it in a stable readable condition I'll post it.. At the moment it's a mess.

  16. #16
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,457

    Re: Excel Memory Use & File Size

    Probably a stupid question but, if you can open the workbook, can't you just copy the "live" rows to a new workbook and save that?

    Regards

  17. #17
    Valued Forum Contributor
    Join Date
    08-22-2011
    Location
    Auckland
    MS-Off Ver
    Excel 2019
    Posts
    716

    Re: Excel Memory Use & File Size

    I've managed to get the file to open & stay open. I'm copying the formulas from it to a new workbook, basically starting again. If it plays up when it's set up, I'll be back. Otherwise I'll start a new thread regarding event handling macros. I'll do that when I've got more time.
    But it does look like excel has problems with memory usage. That's what I've summised from my googling

  18. #18
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,457

    Re: Excel Memory Use & File Size

    Good luck. With Excel 2007, I think you have an awful lot of scope for generating memory issues, given that there are over a million rows. So, if you're going to fill them with "empty" formula, that's got to hurt. Even with Excel 2003, if you fill 10,000 rows by 20 columns with formula to "allow for future expansion" it makes for a big and slow workbook. Especially if that's repeated across several sheets. One of the places I worked had a workbook like that and it was virtually unusable. I tried to get them to change it but they wouldn't have it.

    Let me know if you want help with the Change event handling

    Regards, TMS

  19. #19
    Valued Forum Contributor
    Join Date
    08-22-2011
    Location
    Auckland
    MS-Off Ver
    Excel 2019
    Posts
    716

    Re: Excel Memory Use & File Size

    Thanks TMS I will.
    The very first time I had a play with a spreadsheet was when MS works came with one of my first (386/486) computers. I could have sworn it came with some sort of auto formula advancing feature similar to the event handling we're talking about. I'm probably wrong lol. That was the only contact I've had with spreadsheets until about 4 months ago.
    When I've got it sorted & working, I'll post it here for you all to see & hopefully suggest some improvements. I have 3 dynamic charts, so I'm sure there's a way of making that work more efficiently
    Cheers

  20. #20
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,457

    Re: Excel Memory Use & File Size

    If you want to autofill formulae, there are a couple of options other than VBA. You can switch on the option to autofill formulae (in Excel options) or you could turn your data into a table

    Regards, TMS

+ 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