![]() |
Excel 2000, 2003 crashes on opening
Hi,
I have written some VBA behind an excel 2000 workbook. On some PCs, Excel crashes when opening the workbook (it has happened with 2000 and 2003). When I say crash, I mean the whole program crashes and the popup asking to send info to Microsoft is displayed. I have tracked down the offending code. It is a class module and I have simplified it so that it still replicates the issue. The module code is: ================================================== Option Explicit Option Base 1 '!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ''''''' TEST / RELEASE SOFTWARE '!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ' Make sure that this is changed in the releas version ' so that all of the debugging is not compiled!!! ' and the error trapping is compiled!!! #Const TEST_VERSION = False '!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! '!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! '!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Dim mtOPCServerName As String Dim mtOPCServerKey As String Private WithEvents mOPCgrpModem As OPCAutomation.OPCGroup Private Sub blah() MsgBox "sdff" End Sub ================================================== === There is no code anywhere else in the workbook (i.e. the class isn't even used). Now, the class does reference a dll, but even if that dll does not exist on the PC, excel should not crash on opening (and it doesn't on many PCs. And on some PCs it does crash even if the dll is registered). Can anyone shed some light on this. I tried to contact Microsoft via their email support, but was foiled by bureacracy. Thanks Kalvin Finally, the really dumb thing with it is this: I can fix the issue by opening a new sheet, drawing a button on the sheet and then opening the "crash" workbook. After saving, I can open it on that machine for ever! |
All times are GMT +1. The time now is 10:37 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com