title: How do I validate email address formatting with the .NET Framework?
body: <p>I want a function to test that a string is formatted like an email address.</p>
  
  <p>What comes built-in with the .NET framework to do this?</p>
  
  <p>This works:</p>
  
  <pre><code>Function IsValidEmailFormat(ByVal s As String) As Boolean
      Try
          Dim a As New System.Net.Mail.MailAddress(s)
      Catch
          Return False
      End Try
      Return True
  End Function
  </code></pre>
  
  <p>But, is there a more elegant way?</p>