LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default Stop the Debug option from coming up

I have a code which asks the user to input a password before it will continue
with the code. If the password is incorrect it puts up a message box which
informs the user. At this point, I get the microsoft error message which
gives the user the option to debug............ I don't want this to occur.

Is there any way I can stop the microsoft error message from coming up?

My current code looks like:

Dim MyStr1 As String, MyStr2 As String
MyStr2 = ("admin") 'This is the password and it is CASE sensitive
MyStr1 = InputBox("Password Required")
If MyStr1 = MyStr2 Then
ActiveSheet.Unprotect Password:=MyStr1
Else
MsgBox ("Access Denied")
End If

Rest of code.....................

Thanks in advance.
 
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
Save as .xla option is not coming when I try to save Parag Excel Discussion (Misc queries) 3 January 28th 09 06:28 AM
How to stop Option Button unselecting one on different worksheet? nesmith6866 Excel Discussion (Misc queries) 1 December 14th 06 12:49 AM
stop all the columns coming up the same length in a chart prinshin Charts and Charting in Excel 1 April 21st 06 10:38 AM
VBE Options: Disabling Debug Option on All Errors JGS Excel Programming 1 December 4th 05 10:05 PM
VBA Crashes Excel on Compile or Stop Debug Frank & Pam Hayes[_2_] Excel Programming 0 June 24th 04 09:52 PM


All times are GMT +1. The time now is 01:32 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"