Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 37
Default avoid reset after CodeModule InsertLines

Reset only occurs if changes are made to executing code

That is not what I see.
I have the code that alters the VBE in a normal module. Code in the userform
(modeless userform)
calls the VBE altering code. The code that is altered is in another normal
module. This other module
has no other code at all and is not called. Still, the reset happens.
It looks the only way you can do this is to put the code to be altered in
another workbook.
That works kind of OK. Module level variables and global variables are still
still there after the code is
altered and while running the altered code. But when the execution of the
altered code is finished
then those variables are reset. The other workbook helps out here, because
it is not running that userform.
I suppose one possible solution would be to run the userform from another
workbook or from an ActiveX dll
but that would be way too much work for too little gain.

RBS


"GS" wrote in message ...
As an after thought, you could put the code in a standard module and call
it from your userform at runtime. Reset only occurs if changes are made to
executing code. A procedure in a standard module won't be executing until
you call it *after* the rewrite.

--
Garry

Free usenet access at http://www.eternal-september.org
Classic VB Users Regroup!
comp.lang.basic.visual.misc
microsoft.public.vb.general.discussion



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
InsertLines Syntax Stephen Newman[_2_] Excel Programming 2 July 8th 08 11:13 AM
Problem in InsertLines and CreateEventProc [email protected] Excel Programming 1 November 18th 05 12:06 PM
InsertLines crashes Excel asleeper Excel Programming 5 October 14th 05 05:13 AM
InsertLines crashes Excel Andy Sleeper Excel Programming 3 August 29th 05 05:57 AM
InsertLines and AddFromString crash excel Chip R. Excel Programming 1 August 13th 04 03:28 PM


All times are GMT +1. The time now is 01:54 AM.

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

About Us

"It's about Microsoft Excel"