![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Join Date: Mar 2002
Posts: 26
|
Im still working on the password entry thing.Dim strPass As String
Dim iTries As Integer Private Sub CommandButton1_Click() strPass = TextBox1.Text Do Until iTries = 3 If strPass = "Password" Then MsgBox "Log in OK!" Run "signin" End End If MsgBox "Log in NOT OK!" iTries = iTries + 1 Exit Do Loop End Sub Is it possible to use a number of diffrent passwords, rather than a signgle set password??? I'll work on it, untill any sugestions, thanx alot Craig |
|
|
|
|
|
#2 |
|
.
Join Date: Feb 2002
Location: Akron, Ohio USA
Posts: 758
|
Instead of an If, use a Select:
Select Case LoginID Case "pass1", "pass2", "pass3" Msgbox "Login OK" Case Msgbox "Not OK" End Select
__________________
Preview my latest book for Free |
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|