MailMessage.Dispose Method ()
Releases all resources used by the MailMessage.
Assembly: System (in System.dll)
Call the MailMessage. The method leaves the MailMessage in an unusable state. After calling , you must release all references to the MailMessage so the garbage collector can reclaim the memory that the MailMessage was occupying. For more information, see Cleaning Up Unmanaged Resources and Implementing a Dispose Method.method when you are finished using the
Always call MailMessage.before you release your last reference to the
Available since 2.0