Excel Workbook Size Reduction Revisited.

Back in January I posted a few ideas to reduce workbook size. This post got quite a few comments, so I’d thought I’d write them up into a proper post.

Also Gorden has noticed a strange thing happening, so I wanted to highlight that a bit better too.

Here is a check list!

  • Zip the file!
  • Used Range see here.
  • Removing any VBA code
  • Remove Formatting.
  • Use Rob Bovey’s code clearer
  • Duplicate pivotcaches (ethoros)
  • Excel Filter Ranges (Gordon)
  • Embedded Pictures  (Jon von der Heyden)
  • XL 2007, Store as .xlsb  (sam)
  • VlookUps, External data (Charlie Hall)

Please check back in the original post for explanations of these if they don’t make sense.

And here the one Gordon recently found, which is the odd one! What do you make of it?

I recently found a method that can reduce the file size of an Excel file containing significant amounts of VBA, sometimes by as much as 50%.

  1. Note file size
  2. Open file but do not enable VBA/macros
  3. Make no changes
  4. Save & close file
  5. Check file size again

Even after using Rob Bovey’s Code Cleaner this can sometimes make a huge difference to the size of the file. Many of the workbooks I manage are read-only and reside on a network share somewhere, and as this can make these files much smaller (1300KB down to 700KB etc.) it improves load times, particularly over VPN connections, resulting in an improved user experience.

The files work exactly the same after this is carried out and although I’ve done some examination to see what might have changed I’ve not managed to find anything. Most likely some internal decrofting* is responsible, but I’ve really no idea why this works.

I’ve just tried this on a file and it went form 7.2 megs to 6.6 megs, not bad for doing nothing.

I cant think what it would be that causing this, maybe P-code compilation or something?

* decrofting, some sort of Scottish thing. Crofting is small scale land sharing for framing, so decrofting must be the un sharing of land… or something!

Read this, its (about) the Law

A while back JW notice that some clever chap had been ripping content from his, and other peoples Excel blogs, and reposting it, un attributed. A bit more dig from part time PI Deb Dalgleish unearthed a few sites, all belonging to the same chap, with yet more content theft. Some of the stuff was from this blog, and I tried to get Microsoft to take it down. No luck there and I gave up.

Today I saw a tweet from Jimmy saying that he’d just raised “another” DMCA

Don't mess with the Jimster

Anyway, yesterday I listen to this podcast from Dot Net Rocks, which is about copyright trademarks and so on in software. It’s really interesting, and might be useful.

Quickie: Colour Style of Bar Chart Bars

Just a quick one.

I notice that I often apply a fade effect to the bars of my bar charts, to me it looks a bit nicer.

With fade…

Without fade…

Its not too important, I think the options are:

1. Fade is best

2. Solid is best

3. Ross, you wasting my dam time, you’re a moron!

What do you think?

The MIE Podcasts – Mike Woodhouse

What can you say about Mike Woodhouse that has not already been written? Probably loads. Mike works in London for a rather large international bank, hosts a blog (Grumpy Old Programmer), gets up to all kinds of cool stuff with Ruby, bosses stack overflow (10k rep!), and likes cricket. Oh and he’s not the least bit grumpy.

Mike Woodhouse, he actually looks like this.

In this podcast I chatted to Mike about Test Driven Development, and it place in the Excel/VBA landscape, we also discussed his add in XLUnit, design to help developers test VBA classes using the TDD approach.

Warning, unfortunately the MIE server was a bit rubbish when we did this podcast, so the recording is a poor.  I’ve spent an absolute age editing, but it’s still poor, but stick with it, its worth it.

Why I can’t live without my iPhone.

In fact I don’t have an iPhone. I have a G Phone (a HTC magic (now)), running Android 1.6. But if I’d have said “Why I can’t live without my G Phone”, people might have thought I was on some Android crusade, which I’m not. This post is about “culture”, well ish…

A few weeks ago whilst on a “keeping the wife happy” trip to the theatre, I lost my then phone, (a HTC Hero, running android 1.6 – T-Mobile custom ROM). So I had to go back to the horrible old Sony slide out 9 button jobbie – true evil.

Worst phones maybe available, but it's bloody unlikely

Now I have never insured my phones, I reason that you get a new one ever year, so if you lose it just cut your loses and wait for your contract to be renewed. And anyway, insurance like this is a massive con right, £70 a year for a free “£350” phone. Unless you’re especially gifted, you’re only likely to lose once every 3 years.

So there I was with the telephonic progeny of Satan pressed up against one ear, and this funny, odd feeling in the other (- ear, and not, I’m happy to add the afore mentioned wife!).

Now, I wouldn’t go as far as to say that I had mobophobia, but I did long for the old days. No podcasts on the way home, No Google maps if I got lost, no tunes to listen to at the drop of a hat. Not insurmountable problems I grant you, but why be without the “luxury” when its no great shakes to have it?

So there you go, I went and got a new phone. Now I have it all back, and it feels so good!! Podcasts, mp3’s, chess games, shazam, twitter, the ability to Sky+ TV programmes I don’t really want to watch form the comfort of the pub, and a practically limitless amount of other rubbish that I don’t really want or need. But I can have it, I can have it all, and now I’ve got it I don’t want to give it up!

so there you have it…

Me 0, Mobile phone companies 1!