Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Excel 2000 Macro

I am gettting the following error when trying to compile my excel macro.
"COMPILE ERROR: PROCEDURE TOO LARGE"
How do I get around this error message and allow excel to compile my
auto_open macro?

Thanks in advance.
Keven

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Excel 2000 Macro

Break the procedure in to two or more smaller procedures,
passing, if necessary, variables from one procedure to the next.
Good structured programming techniques would already lead you
down this path.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com

"Keven Swingle" wrote in
message
...
I am gettting the following error when trying to compile my
excel macro.
"COMPILE ERROR: PROCEDURE TOO LARGE"
How do I get around this error message and allow excel to
compile my
auto_open macro?

Thanks in advance.
Keven



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Excel 2000 Macro

break up your code into more than one module.

--
Regards,
Tom Ogilvy

"Keven Swingle" wrote in message
...
I am gettting the following error when trying to compile my excel macro.
"COMPILE ERROR: PROCEDURE TOO LARGE"
How do I get around this error message and allow excel to compile my
auto_open macro?

Thanks in advance.
Keven



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,327
Default Excel 2000 Macro

Hi keven

Adding to the others a small sample. Macros can /should be in separate
modules:

Sub Auto_open()
Call PartOne
Call PartTwo
Call PartThree("Tada !")
End Sub

Sub PartOne()
MsgBox "Hi"
End Sub

Sub PartTwo()
MsgBox "Bye"
End Sub

Sub PartThree(strMsg As String)
MsgBox strMsg
End Sub

HTH. Best wishes Harald

"Keven Swingle" skrev i melding
...
I am gettting the following error when trying to compile my excel macro.
"COMPILE ERROR: PROCEDURE TOO LARGE"
How do I get around this error message and allow excel to compile my
auto_open macro?

Thanks in advance.
Keven



  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Excel 2000 Macro

Thank you for the example, really helped to clarify what the others where
saying, I am very new to programming and greatly appreciate the assistiance.

"Harald Staff" wrote:

Hi keven

Adding to the others a small sample. Macros can /should be in separate
modules:

Sub Auto_open()
Call PartOne
Call PartTwo
Call PartThree("Tada !")
End Sub

Sub PartOne()
MsgBox "Hi"
End Sub

Sub PartTwo()
MsgBox "Bye"
End Sub

Sub PartThree(strMsg As String)
MsgBox strMsg
End Sub

HTH. Best wishes Harald

"Keven Swingle" skrev i melding
...
I am gettting the following error when trying to compile my excel macro.
"COMPILE ERROR: PROCEDURE TOO LARGE"
How do I get around this error message and allow excel to compile my
auto_open macro?

Thanks in advance.
Keven




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Macro in Excel 2000 Raymond Dorais Excel Discussion (Misc queries) 1 January 17th 06 03:08 AM
Macro in Excel 2000 Marcin_71 Excel Discussion (Misc queries) 6 August 19th 05 03:22 PM
translate lotus 1-2-3 macro into excel macro using excel 2000 krutledge0209 Excel Programming 1 November 2nd 04 05:50 PM
Create macro to download access 2000 table to excel 2000 spreadsheet Tushar[_2_] Excel Programming 3 October 21st 04 02:44 PM
Excel 2000 Macro No Name Excel Programming 1 December 27th 03 04:44 PM


All times are GMT +1. The time now is 05:42 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"