This snippet generates sends mail using System.Web.Mail namespace
<%@Page Explicit="False" Language="VB" Debug="True" %>
<%@Import Namespace="System.Web.Mail" %>
<%
Dim ETo As String = "set to mailid"
Dim EFrom As String = "set from mailid"
Dim ESub As String = "Test Mail"
Dim EBody As String = "Testing mail send option in asp.net"
System.Web.Mail.SmtpMail.Send(EFrom, ETo, ESub, EBody)
Response.Write ("Mail sent Successfully.")
%>