Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 441
Default Force code to compile

Once a long time ago, Tom Ogilvy passed a short code to me that would
essentially simulate a click of the [Compile VBAProject] button in the VBE.
The objective is to force the code in the current module to (re)compile.

I didn't have any luck searching for it. Could someone (if not Tom) please
post this code again? Thanks.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Force code to compile

How about:

thisworkbook.VBProject.VBE.CommandBars("Menu Bar"). _
controls("Debug").Controls("Compi&le VBAProject").Execute

--
Regards,
Tom Ogilvy


"quartz" wrote in message
...
Once a long time ago, Tom Ogilvy passed a short code to me that would
essentially simulate a click of the [Compile VBAProject] button in the

VBE.
The objective is to force the code in the current module to (re)compile.

I didn't have any luck searching for it. Could someone (if not Tom) please
post this code again? Thanks.



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 441
Default Force code to compile

That's the one! Thanks again Tom.

"Tom Ogilvy" wrote:

How about:

thisworkbook.VBProject.VBE.CommandBars("Menu Bar"). _
controls("Debug").Controls("Compi&le VBAProject").Execute

--
Regards,
Tom Ogilvy


"quartz" wrote in message
...
Once a long time ago, Tom Ogilvy passed a short code to me that would
essentially simulate a click of the [Compile VBAProject] button in the

VBE.
The objective is to force the code in the current module to (re)compile.

I didn't have any luck searching for it. Could someone (if not Tom) please
post this code again? Thanks.




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
Compile VBA code? (Passwording too weak a protection scheme?) [email protected] Excel Discussion (Misc queries) 1 August 20th 06 04:57 PM
code to force xls file to open after several hours passed helmekki[_10_] Excel Programming 1 June 10th 04 03:04 AM
Compile VBA code Eric[_14_] Excel Programming 1 December 28th 03 03:36 AM
Compile Error in Code Phil Hageman[_3_] Excel Programming 9 October 29th 03 08:52 PM


All times are GMT +1. The time now is 12:33 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"