Send Mail Socket with google issues

So I am getting a bug (NilObjectException) with trying to send emails via through port 465. Using any of the SMTP services listed here did not aid in trying to send the email.

Code that is causing issues is below:

[code] dim SendMailSocket as SMTPSocket

  SendMailSocket.Address = "" // your SMTP email server
  SendMailSocket.Port = 465 // Check your server for the property port # to use



Thank you so much ladies and gents.

You have not created an instance of SendMailSocket - add New to the Dim statement.

Also you should be using SMTPSecureSocket and setting the security to TLS.