It can get fancier than this, but this is a fairly quick and dirty approach:
Code:
Private Sub CommandButton1_Click()
Dim ans As String
ans = InputBox("Please enter a password to unlock the sheet", "Password required")
If ans <> "bigdog" Then
MsgBox "Sorry Charlie, but you got it wrong", vbInformation + vbOKOnly, "Buy Bye"
Exit Sub
Else: ActiveSheet.Unprotect "password"
End If
End Sub
Hope that helps,
Smitty