Dart.Mail Namespace > Smtp Class : GetDefaultPort Method |
Public Shared Function GetDefaultPort( _ ByVal session As SmtpSession _ ) As Integer
Dim session As SmtpSession Dim value As Integer value = Smtp.GetDefaultPort(session)
public static int GetDefaultPort( SmtpSession session )
public: static int GetDefaultPort( SmtpSession* session )
public: static int GetDefaultPort( SmtpSession^ session )
Returns 587 (the well-known SMTP submission port) if SmtpSession.UseSubmissionPort is true, and 25 (the well-known SMTP server port) if false. If MailSecurity.Encrypt == Encrypt.Implicit, returns 465 (the well-known secure SMTP port).
Used to initialize Session.RemoteEndPoint.Port if not initialized by the user.