Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Compile error in hidden module
Hi, I have password protected my excel macros and thus they are hidden fro others that use it. However when there is a 'compile error' I automaticly receive an erro message "Compile error in hidden module:Module1". Is there any way that I can change that error message to read somethin like this :- "Complile error - contact Bernz and advise exactly what you were doin at the time of the error message" Cheers, Bern -- Bernz ----------------------------------------------------------------------- BernzG's Profile: http://www.excelforum.com/member.php...fo&userid=2294 View this thread: http://www.excelforum.com/showthread.php?threadid=38819 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Compile error in hidden module
I don't think you can intercept this message and make it do what you want.
In fact, I don't think you can do much with a compile error. But you could compile your project before you release it to others. Inside the VBE Debug|Compile VBAProject BernzG wrote: Hi, I have password protected my excel macros and thus they are hidden from others that use it. However when there is a 'compile error' I automaticly receive an error message "Compile error in hidden module:Module1". Is there any way that I can change that error message to read something like this :- "Complile error - contact Bernz and advise exactly what you were doing at the time of the error message" Cheers, Bernz -- BernzG ------------------------------------------------------------------------ BernzG's Profile: http://www.excelforum.com/member.php...o&userid=22949 View this thread: http://www.excelforum.com/showthread...hreadid=388193 -- Dave Peterson |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Compile error in hidden module
recipient may still get the compile errors.
if he has a different excel version, or missing references to activex objects/libraries) -- keepITcool | www.XLsupport.com | keepITcool chello nl | amsterdam Dave Peterson wrote : I don't think you can intercept this message and make it do what you want. In fact, I don't think you can do much with a compile error. But you could compile your project before you release it to others. Inside the VBE Debug|Compile VBAProject |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Compile error in hidden module
Good point.
keepITcool wrote: recipient may still get the compile errors. if he has a different excel version, or missing references to activex objects/libraries) -- keepITcool | www.XLsupport.com | keepITcool chello nl | amsterdam Dave Peterson wrote : I don't think you can intercept this message and make it do what you want. In fact, I don't think you can do much with a compile error. But you could compile your project before you release it to others. Inside the VBE Debug|Compile VBAProject -- Dave Peterson |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Compile error in hidden module
Hi, Thanks for this. Yes compile errors should be picked up in the first place when creating and testing the macro - should have realised that. I got it wrong in that I was wanting the intercept and replace a "runtime" error message when a user does something that I have not thought of or tested for. Example of the error message:- "Microsoft Visual Basic Run time error ########### Automation error The error invoked has been disconnected from its clients" Also exited completely out of Excel - stating reporting error Can this message be replaced with my own message as stated previously. Cheers, Bernz -- BernzG ------------------------------------------------------------------------ BernzG's Profile: http://www.excelforum.com/member.php...o&userid=22949 View this thread: http://www.excelforum.com/showthread...hreadid=388193 |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Compile error in hidden module
You could add some error handling to each sub:
option explicit sub mysub() on error goto errhandler: 'do lots of stuff exit sub errhandler: msgbox err.number & vblf & err.description end sub BernzG wrote: Hi, Thanks for this. Yes compile errors should be picked up in the first place when creating and testing the macro - should have realised that. I got it wrong in that I was wanting the intercept and replace a "runtime" error message when a user does something that I have not thought of or tested for. Example of the error message:- "Microsoft Visual Basic Run time error ########### Automation error The error invoked has been disconnected from its clients" Also exited completely out of Excel - stating reporting error Can this message be replaced with my own message as stated previously. Cheers, Bernz -- BernzG ------------------------------------------------------------------------ BernzG's Profile: http://www.excelforum.com/member.php...o&userid=22949 View this thread: http://www.excelforum.com/showthread...hreadid=388193 -- Dave Peterson |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
Compile error in hidden module
Thanks Dave -- Bernz ----------------------------------------------------------------------- BernzG's Profile: http://www.excelforum.com/member.php...fo&userid=2294 View this thread: http://www.excelforum.com/showthread.php?threadid=38819 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
compile error in hidden module | Excel Discussion (Misc queries) | |||
compile error in hidden module | Excel Discussion (Misc queries) | |||
compile error in hidden module..... | Excel Programming | |||
compile error in hidden module | Excel Programming | |||
Compile error in hidden module | Excel Programming |