Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,253
Default Disable the "X" close button in an excel application



OFF TOPIC?

Hi Jan Karel,

I've never knew you could have bloat in thisworkbook..

I honestly thought codebloat could only exist in userforms, where the
compiled parts (the frx) contains dirt from unused objects.
(I've also had some troublesome experiences with FlexGrids, which have
some nasty habits)

I can imagine the flexgrid problems popping up in sheets, but then that
would bloat the sheet object being the container of the troublesome
activeX... and i doubt the problems would be solved by exporting/
importing the code as that wouldnt affect the sheet's objects.
(I'll test that)

Codebloat in normal or class modules theoretically doesnt make sense.
(note that some filereduction from CodeCleaner is achieved simply by
saving it in decompiled state)

You wouldn't have an example of bloated code (in a plain or workbook
module) somewhere on your harddisk, would you?

I'd love to have a look.


--
Jurgen
| www.XLsupport.com | keepITcool chello nl | amsterdam


Jan Karel Pieterse wrote :

Hi Bob,

It is better, IMO as well as yours, as it saves on that unnecessary
class module,


I must say I disagree on that point.

Class modules can easily be cleaned by an export/remove/import cycle
(or by using Rob Bovey's code cleaner), but the Thisworkbook module
cannot be removed.

So when a bloat creeps into the Thisworkbook module, one will have to
start with a fresh workbook to remove it.

This my main reason why I try to keep the Thisworkbook module as slim
as I possibly can.

Regards,

Jan Karel Pieterse
Excel MVP
http://www.jkp-ads.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 535
Default Disable the "X" close button in an excel application

Hi KeepITcool,

Codebloat in normal or class modules theoretically doesnt make sense.
(note that some filereduction from CodeCleaner is achieved simply by
saving it in decompiled state)


It happens though. I have seen a couple of workbooks of mine go
haywire, which mostly could be fixed by a code cleaning job.
Mostly it requires Modules that contain quite some code (50K or more)
and have been heavily edited in the past without ever cleaning up.

One was even corrupted so bad I had to copy the code to Notepad and
paste that back after inserting a new module.

The symptom it showed was that I would get a compile error (object
doesn't support this property or method!) on this kind of line:

sTemp=Thisworkbook.worksheets("Sheet1").Range("A1" ).Value

Note the lack of capitalisation of the worksheets collection!

You wouldn't have an example of bloated code (in a plain or workbook
module) somewhere on your harddisk, would you?


Sorry, this was a customer workbook I cannot share.

Regards,

Jan Karel Pieterse
Excel MVP
http://www.jkp-ads.com

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
Disable the "X" close button in an excel application Patrick Molloy[_2_] Excel Programming 3 April 19th 05 08:28 AM
Disable the "X" close button in an excel application keepITcool Excel Programming 1 April 18th 05 11:28 AM
Disable Close "X" button on User Forms Celtic_Avenger[_50_] Excel Programming 0 October 11th 04 06:25 PM
Disable Close "X" button on User Forms Celtic_Avenger[_49_] Excel Programming 2 October 11th 04 06:20 PM
SIMPLEST way to disable "close" button on form? codytheretriever Excel Programming 4 August 7th 03 09:00 PM


All times are GMT +1. The time now is 06:55 PM.

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"