ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Compile error macro is 111K. how do I fix macro (https://www.excelbanter.com/excel-programming/383450-compile-error-macro-111k-how-do-i-fix-macro.html)

Dricon1

Compile error macro is 111K. how do I fix macro
 
How can I fix the macro to run. I know 64K is the maximum allowed so how can
split into two macro?

Jim Cone

Compile error macro is 111K. how do I fix macro
 

Using my x-ray vision and psychic abilities, I have determined you can reduce
the size of your code by eliminating all of the "Select" statements and also
looping thru cell ranges instead of specifying each cell that you need to change.
After doing the above, splitting the code will be easier to accomplish and
may even not be needed.
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware


"Dricon1"
wrote in message
How can I fix the macro to run. I know 64K is the maximum allowed so how can
split into two macro?

gerdmain

Compile error macro is 111K. how do I fix macro
 
Hi,

I am surprised that you can write a macro of this size in the first place.
You to make it easier to debug, I generall ybreak the code into several
sub-routines like:

sub Main()

call Initiate
call get_Input
call Process
call Cleanup

end sub

Chances are that each of these Sub-routines will again be broken down
further, and will call internal Functions to simplify the code further.

A proper, logical design makes coding and debugging so much easier.

Hope this helps.
And there will usually be a number of internal Functions.
--
Gerd


"Dricon1" wrote:

How can I fix the macro to run. I know 64K is the maximum allowed so how can
split into two macro?



All times are GMT +1. The time now is 07:47 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com