Sub SignIn() Dim secretCode As String Do secretCode = InputBox("Enter your secret code:") If secretCode = "sp1045" Then Exit Do Loop While secretCode <> "sp1045" End Sub