Connect Summary Connect to FTP server. The Connect method establishes a connection to the FTP server. User and Password must contain a valid user name and password to complete the login process.
Some servers also require that Account contain the name of an account for the user.
If the server does not require the name of an account for the user, then Account can be set to an empty string. The application should ensure that the method was successfully executed by checking the return value. The method also sets the LastResult property. The value of the LastResult property can be checked to determine if any error occurred. If the connection can be established, then the OnConnect event will be fired.