|
-
Aug 9th, 2002, 03:08 PM
#1
Thread Starter
New Member
Simple e-mail form
Hello! I want to make a e-mail form with a simple code. This code I want to use it into my personal web page. If there is anyone who can help me please put here a simple code. Please help me with this 'cause I am a beginner into ASP and I want to learn this.
-
Aug 14th, 2002, 04:11 PM
#2
Member
ASP.NET makes it easy to send e-mails from a web server. For example if you have an Apply button, and 3 textboxes the user fills in. On the button click event, you could have for example...
Private Sub cmdApply_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cmdSearch.Click
Dim NewMessage As New System.Web.Mail.MailMessage()
NewMessage.To = txtTo.Text
NewMessage.From = "[email protected]"
NewMessage.Subject = txtSubject.Text
NewMessage.Body = txtBody.Text
System.Web.Mail.SmtpMail.Send(NewMessage)
End Sub
Of course there's no validation shown here, but its a starting point.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|