why does my excel file size increase when I use visual basic editor

  • Thread starter Thread starter R.H.
  • Start date Start date
R

R.H.

I am automating an excel spreadsheet by using a userform with several
textboxes and a flexgrid. It works fine, but every so often for
whatever reason, the file size of the excel file increases in a very
large manner. I started with a 43kb file and it was working fine. Then
I noticed my machince was so and when I checked the file size it was
like 33Mb, but if I go back to the original file and redo everything it
is fine again for a while. Does anyone know what causes this? It has
happened in both Windows XP and Windows 2000.

Roger
 
I've seen this happen when some userform controls go crazy.

With a copy of your workbook, try removing userforms one-by-one until you
find the faulty userform (the filesize should decrease)
Then from that userform, try removing controls one by one until you find
which one is at fault.

If you find a broken control, just remove it and add it back in again.
 
Back
Top