ALM Site Administration API Type Library 12.50 and later
Login Method
The URL in the format http://<server name>[:<port>]/qcbin.
The user name defined in the ALM database.
The user's password.
Description
Logs the specified user on to the site administration application.
Syntax
Visual Basic
Public Sub Login( _
   ByVal ServerURL As String, _
   ByVal UserName As String, _
   ByVal password As String _
) 
Parameters
ServerURL
The URL in the format http://<server name>[:<port>]/qcbin.
UserName
The user name defined in the ALM database.
password
The user's password.
Example
Private Function LogOn(URL As String, UserName As String, pwd As String) As Boolean
On Error GoTo LogOnErr
    ' Get administrator connection
    If m_SAClient Is Nothing Then Set m_SAClient = New SAapi
    'Note: Release this connection before program exits, for example,
    '  in Form_Unload event
    '    Set m_SAClient = Nothing
    
    'Log on
    m_SAClient.Login URL, UserName, pwd
    
    LogOn = PASS
Exit Function
LogOnErr:
    LogOn = FAIL
    MsgBox "Logon Failed" + err.Description
    
End Function
See Also

SAapi Object  | SAapi Members