richarddawson

Board Regular
Joined
Oct 18, 2014
Messages
72
I have two data files, containing very different material, but both of length 45,737 KB. I am running on a 64bit version.

Now that seems to be rather too big a coincidence. I know file sizes are not meant to be limited, but I am concerned in case there is some restriction in fact.

This is important to me as both files will grow with time, and I am concerned I may have future difficulties - perhaps the files becoming unreadable.
 

Some videos you may like

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.

Jon Peltier

MrExcel MVP
Joined
May 14, 2003
Messages
4,922
Office Version
  1. 365
Platform
  1. Windows
  2. MacOS
What kind of file? Have you inspected their contents?
 

Logit

Well-known Member
Joined
Aug 31, 2016
Messages
3,602
.
Trying to understand your issue. It sounds like your workbook/s are bigger in size than they should be based on the amount of
data/macros you currently have in the workbook ?

If this is the case ...

Make a COPY OF YOUR WORKBOOK. ONLY RUN THIS ON A COPY FIRST !! If it works, then run it on the original file.

Paste this macro into the workbook and run it. It's purpose is to remove extraneous invisible data in the worksheets that EXCEL sometimes
creates without you being aware.

Code:
Sub LipoSuction()
'JBeaucaire (8/3/2009)
Dim LR As Long, LC As Long
Dim ws As Worksheet


For Each ws In Worksheets
    LR = ws.Range("A" & ws.Rows.Count).End(xlUp).Row + 1
    LC = ws.Cells(1, ws.Columns.Count).End(xlToLeft).Column + 1


    'Clear everything below column A last cell and row 1 last cell
        ws.Range(ws.Cells(1, LC), ws.Cells(ws.Rows.Count, ws.Columns.Count)).Clear
        ws.Range(ws.Cells(LR, 1), ws.Cells(ws.Rows.Count, ws.Columns.Count)).Clear
Next ws


End Sub



Here is another example that does the same thing. Again, paste macro into your COPY OF WORKBOOK, then run the macro.

https://www.amazon.com/clouddrive/share/bWTBapIirV2k553ycNe7J8I0AxoSx5ehKeaYpJS2bfY
 

richarddawson

Board Regular
Joined
Oct 18, 2014
Messages
72
Yes, I have inspected the files, frequently in fact.

One contains daily (weekdays only) closing prices for 2,240 companies from 1995 to now. The other contains monthly data for each of those companies for the same dates. But the latter only contains only 7 items per month, while there are about 20 (19 - 22) prices per month, so they should not be the same size.
 

MARK858

MrExcel MVP
Joined
Nov 12, 2010
Messages
13,336
Office Version
  1. 365
  2. 2010
Platform
  1. Windows
  2. Mobile
Then run the macro Logit posted on a copy of your workbook as suggested to see if it makes a difference (just change the .Clear to .Delete)
 
Last edited:

richarddawson

Board Regular
Joined
Oct 18, 2014
Messages
72
Thanks for the suggestion. The LipoSuction made no difference to the spreadsheet I thought should be larger.
However the "smaller" one was very odd. Before backing up it was 45,27KB, but after lots of backing up, it has reverted to 14,304KB, unfortunately I only suddenly noticed it so do not know what happened. But I do know I hadn't run the LipoSuction. When I did it reduced it to 14,303KB.

So I think the problem is solved - but Heaven knows how!
 

Watch MrExcel Video

Forum statistics

Threads
1,109,451
Messages
5,528,836
Members
409,839
Latest member
akashsadhu
Top