Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Minimizing/Compressing VB Code in Excel File ...
Hello -
I was wondering if there is a way to somehow reduce the size of the VB code so that the Excel file gets smaller. I have developed some code in a template that will be used many times and I would like to reduce the file size. Is there some way of compressing it? I was thinking about stripping out all leading tabs/spaces and comments? Is there anything else I could do? Thanks! Joe |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Minimizing/Compressing VB Code in Excel File ...
Another thing to try, which I don't think Rob's utility does, is to
re-create the project, by exporting the modules, and then importing then into a new workbook. This often reduces the size (but it starts to grow again as you further develop <g). -- HTH RP (remove nothere from the email address if mailing direct) "Joe HM" wrote in message oups.com... Hello - I was wondering if there is a way to somehow reduce the size of the VB code so that the Excel file gets smaller. I have developed some code in a template that will be used many times and I would like to reduce the file size. Is there some way of compressing it? I was thinking about stripping out all leading tabs/spaces and comments? Is there anything else I could do? Thanks! Joe |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Minimizing/Compressing VB Code in Excel File ...
Hello -
Thanks so much for the feedback! I tried Rob's utility and it actually exports the modules and then re-imports them. That reduced the size of the file. Then I used it to strip out comments and spaces. The only thing I noticed is that when I did the export and re-import AND stripping at the same time, Excel crashed. Weird ... Thanks again! Joe |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Minimizing/Compressing VB Code in Excel File ...
Rob Bovey has documented this problem which relates to stripping in class
modules like ThisWorkBook and Sheet modules. It's particularly problematic in XL97 but I've also had this problem in XL2K (not often). In Options, check "Ignore code behind document objects when stripping" Regards, Peter T "Joe HM" wrote in message oups.com... Hello - Thanks so much for the feedback! I tried Rob's utility and it actually exports the modules and then re-imports them. That reduced the size of the file. Then I used it to strip out comments and spaces. The only thing I noticed is that when I did the export and re-import AND stripping at the same time, Excel crashed. Weird ... Thanks again! Joe |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Workbook protection impacts file size when compressing a spreadshe | Excel Worksheet Functions | |||
compressing an Excel file | New Users to Excel | |||
Compressing Pictures in Excel | Excel Discussion (Misc queries) | |||
Import VBA Code in Excel-File ? (Export VBA Code to file) | Excel Programming | |||
Minimizing Excel from a Macro | Excel Programming |