#include #include Func newf() TCPStartup() Local $s_ipaddress = "216.58.223.197" Local $s_port = "465" Local $i_socket, $s_error Local $i_socket = TCPConnect($s_ipaddress, $s_port) If @error Then $i_error = @error MsgBox(BitOR($MB_SYSTEMMODAL, $MB_ICONHAND), "", "Could not connect, Error code: " & $s_error) Else MsgBox(16, "connected", "connected to gmail server", 20) EndIf TCPCloseSocket($i_socket) EndFunc Func smtpp() Local $smtp_server = "smtp.gmail.com" Local $s_FromName = "seun oyebowale" Local $from_address = "oyebowalemuiz@gmail.com" Local $to_address = "gatescode214@gmail.com" Local $subject = "test" Local $s_password = "OluwaseunOyebowale@25" Local $ssl = 0 Local $s_body [2] $s_body[0] = "i love new york" $s_body[1] = "this just shows it worked" Local $iResponse = _INetSmtpMail($smtp_server, $s_FromName, $from_address, $to_address, $subject, $s_body, $s_password, $ssl) Local $iErr = @error If $iResponse = 1 Then MsgBox($MB_SYSTEMMODAL, "Success!", "Mail sent") Else MsgBox($MB_SYSTEMMODAL, "Error!", "Mail failed with error code " & $iErr) EndIf EndFunc