Diclare a global variable
call this function in your script.
Code:
Dim bLoggedIn = False
Function Login()
if bLoggedIn = False Then
"Login here"
bLoggedIn = True
End If
End Functioncall this function in your script.

