ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Help - Change Event triggered on File Save As (https://www.excelbanter.com/excel-programming/280727-help-change-event-triggered-file-save.html)

Dee Veloper

Help - Change Event triggered on File Save As
 
I have a problem with a simple excel 2002 application I am developing.

Whenever I do a "File Save As" the sub below is triggered.
(To help pinpoint the problem I stripped the application
of every single line of code and added this one below and modified the
offending sub as seen below)

Private Sub ComboBoxPC_Change()
MsgBox "hello"
End Sub


The combo, from the control toolbox, is on a worksheet.

Even though the file is devoid of all code and the combo no longer has
any function the "File Save As" will still trigger the Message dialog
shown above.
A simple file save will not trigger the event.

this is really puzzling, to say the least.

any help would be appreciated. this is driving me nuts.

Tom Ogilvy

Help - Change Event triggered on File Save As
 
Is it linked to a cell. Try removing the link.

--
Regards,
Tom Ogilvy

Dee Veloper wrote in message
m...
I have a problem with a simple excel 2002 application I am developing.

Whenever I do a "File Save As" the sub below is triggered.
(To help pinpoint the problem I stripped the application
of every single line of code and added this one below and modified the
offending sub as seen below)

Private Sub ComboBoxPC_Change()
MsgBox "hello"
End Sub


The combo, from the control toolbox, is on a worksheet.

Even though the file is devoid of all code and the combo no longer has
any function the "File Save As" will still trigger the Message dialog
shown above.
A simple file save will not trigger the event.

this is really puzzling, to say the least.

any help would be appreciated. this is driving me nuts.




steve smallman

Help - Change Event triggered on File Save As
 
The saveas method prompts a recalculation and may make
changes to the open workbook. The saveCopyAs method does
not change the open workbook, and may be of benefit

Steve
-----Original Message-----
I have a problem with a simple excel 2002 application I

am developing.

Whenever I do a "File Save As" the sub below is triggered.
(To help pinpoint the problem I stripped the application
of every single line of code and added this one below and

modified the
offending sub as seen below)

Private Sub ComboBoxPC_Change()
MsgBox "hello"
End Sub


The combo, from the control toolbox, is on a worksheet.

Even though the file is devoid of all code and the combo

no longer has
any function the "File Save As" will still trigger the

Message dialog
shown above.
A simple file save will not trigger the event.

this is really puzzling, to say the least.

any help would be appreciated. this is driving me nuts.
.


Dee Veloper

Help - Change Event triggered on File Save As
 
Hi Tom
I almost never use controls in a worksheet (use them in userforms) but
no, I almost never use the "linkedcell" property and not in this
instance.

However, I did have a "listfillrange" using a named range. That was
the gremlin. Your post allowed me to solve the problem..so thank you
very much!

In passing, I still don't understand why the behaviour..just know that
I have
to code the listfillrange. why would the file save as trigger a change
given the range referenced by the list does not change on a File Save
As?



"Tom Ogilvy" wrote in message ...
Is it linked to a cell. Try removing the link.

--
Regards,
Tom Ogilvy

Dee Veloper wrote in message
m...
I have a problem with a simple excel 2002 application I am developing.

Whenever I do a "File Save As" the sub below is triggered.
(To help pinpoint the problem I stripped the application
of every single line of code and added this one below and modified the
offending sub as seen below)

Private Sub ComboBoxPC_Change()
MsgBox "hello"
End Sub


The combo, from the control toolbox, is on a worksheet.

Even though the file is devoid of all code and the combo no longer has
any function the "File Save As" will still trigger the Message dialog
shown above.
A simple file save will not trigger the event.

this is really puzzling, to say the least.

any help would be appreciated. this is driving me nuts.


Tom Ogilvy

Help - Change Event triggered on File Save As
 
I guess it is recalculated, so it counts as a change.

--
regards,
Tom Ogilvy

Dee Veloper wrote in message
om...
Hi Tom
I almost never use controls in a worksheet (use them in userforms) but
no, I almost never use the "linkedcell" property and not in this
instance.

However, I did have a "listfillrange" using a named range. That was
the gremlin. Your post allowed me to solve the problem..so thank you
very much!

In passing, I still don't understand why the behaviour..just know that
I have
to code the listfillrange. why would the file save as trigger a change
given the range referenced by the list does not change on a File Save
As?



"Tom Ogilvy" wrote in message

...
Is it linked to a cell. Try removing the link.

--
Regards,
Tom Ogilvy

Dee Veloper wrote in message
m...
I have a problem with a simple excel 2002 application I am developing.

Whenever I do a "File Save As" the sub below is triggered.
(To help pinpoint the problem I stripped the application
of every single line of code and added this one below and modified the
offending sub as seen below)

Private Sub ComboBoxPC_Change()
MsgBox "hello"
End Sub


The combo, from the control toolbox, is on a worksheet.

Even though the file is devoid of all code and the combo no longer has
any function the "File Save As" will still trigger the Message dialog
shown above.
A simple file save will not trigger the event.

this is really puzzling, to say the least.

any help would be appreciated. this is driving me nuts.





All times are GMT +1. The time now is 09:04 AM.

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