Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Hi all, I have a button and when pressed would like to say 'Please enter your
password, once the password has been validated the rest of the macro will run. Is this possible? |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Neil,
This a a simple way but you won't get a 'masked' password input box where the characters typed appear as *** or something else. If you want to do that then post back Sub Password() Dim Response As String Dim MyPass As String MyPass = "xxx" Response = InputBox("Enter your password") If Response < MyPass Then MsgBox "Not Authorised" Exit Sub End If 'Your Code End Sub -- Mike When competing hypotheses are otherwise equal, adopt the hypothesis that introduces the fewest assumptions while still sufficiently answering the question. "Neil Holden" wrote: Hi all, I have a button and when pressed would like to say 'Please enter your password, once the password has been validated the rest of the macro will run. Is this possible? |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Sorry you wanted a button on the sheet. Put a button on the sheet, right
click it - view code and paste the code below in. Private Sub CommandButton1_Click() Dim Response As String Dim MyPass As String MyPass = "xxx" Response = InputBox("Enter your password") If Response < MyPass Then MsgBox "Not Authorised" Exit Sub End If Call YourSubName End Sub -- Mike When competing hypotheses are otherwise equal, adopt the hypothesis that introduces the fewest assumptions while still sufficiently answering the question. "Neil Holden" wrote: Hi all, I have a button and when pressed would like to say 'Please enter your password, once the password has been validated the rest of the macro will run. Is this possible? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How do I get 2003 Macros and Toolbar Buttons form Excel 2003 to 20 | New Users to Excel | |||
buttons in excel 2003 | New Users to Excel | |||
Option Buttons from the Forms Toolbar - Excel 2003 | Excel Worksheet Functions | |||
tab scrolling buttons - excel 2003 | Excel Worksheet Functions | |||
excel 2003 - macros & buttons | New Users to Excel |