Noted your advice, alex. Before that, can someone explain to me what does the code below means?
Code:
    Dim tempBoolean As Boolean = False
        If CInt(command.ExecuteScalar()) = 0 Then
            MsgBox("You have not entered the correct password.")
        Else
            tempBoolean = True
        End If
        connection.Close()
        If tempBoolean Then
            ' do something here            
            Me.Hide()
            Admin.Show()
        Else
            ' do something else here        
        End If
    End Sub
I do not understand the part in bold. What is tempBoolean anyway?

Anyway, in the first part of IfElse, since it has stated that the tempboolean = true, in the second part for the tempBoolean IfElse statement, whether the code is written as
Code:
 If tempBoolean Then
or
Code:
 If tempBoolean = True Then
; it can still works?

I'm not able to see the 'link'.