Changing System.Web.Mail to System.Net.Mail

I am trying to learn ASP
I have been using the Visual Web Developer 2005
I have the following line that I can not work out how to convert.

Dim FromForm As String = ""
Dim ToMe As String = ""
Dim FormSubject As String = "Contact Infomation"
Dim EmailText As String = "Blar Blar Blar"
It tells me that I cannot use System.Web.Mail any more and should use System.Net.Mail.
I have been unable to work out what the new code should be to get it to work.
The Language is VB
Can anyone tell me how to change the code to work Please?
I have search every Web Site I could find but they all seem to refer to System.Web.Mail or have pages of code which I am not able to work out which part I need.
Ever hopeful
Steve D Blake
6/16/2005 10:28:26 AM 91979 articles. 4 followers. Follow

3 Replies

Similar Articles

[PageSpeed] 57
Get it on Google Play
Get it on Apple App Store

See a short introduction to System.Net.Mail in this ASPAlliance article by Brad Kingsley: Sending Email from ASP.NET 2.0. 

Terri Morton
Engagement Manager, Neudesic

How to ask a question

6/16/2005 11:12:52 AM
Thanks that helped.
Got to try it out on the web site now.
6/16/2005 1:29:07 PM
As you can set the host, port, and all other kinds of stuff right in Web.Config

             <smtp deliveryMethod="Network">
                         <network defaultCredentials="false" host="" userName="" password="pa$$word" port="25" from=""/>

And now it truly would be "one line of code to send an email"
"If you make it idiot proof, they'll build a better idiot"
6/16/2005 4:45:23 PM

Web resources about - Changing System.Web.Mail to System.Net.Mail -

Changing room - Wikipedia, the free encyclopedia
A changing room , locker room , dressing room (usually in a sports, theater or staff context) or changeroom (regional use) is a room or area ...

Beyond Timeline: The Changing Face Of Facebook Ads
Despite the hype, timeline may not be the most exciting, or important change coming on March 30. Expanded advertising opportunities may unlock ...

Robert Scoble - Micromedia, how it's changing what we blog - Facebook
Jeremiah Owyang wrote an interesting piece about micromedia and how it's changing what we do on blogs and how we distribute media (er, ideas, ...

8 Ways the Changing Facebook Home Page Will Affect Application Virality
For developers who live and die by the changes Facebook makes to the way information flows through the service, every little Facebook tweak has ...

Changing Lanes (@chginglanes) on Twitter
Sign in Sign up To bring you Twitter, we and our partners use cookies on our and other websites. Cookies help personalize Twitter content, tailor ...

Changing the way business decisions are made
We believe that social data has unlimited value, and near limitless application. Today, we’re taking an important step toward unleashing this ...

The Right and Wrong Reasons for Changing Jobs
... your profile is a clue to the folks at LinkedIn that you’re thinking of switching jobs, so don’t be The Right and Wrong Reasons for Changing ...

We're Changing Our Name (Back) to Stack Overflow
We are Stack Overflow. You may know us from such popular websites as Stack Overflow Q&A, Stack Overflow Careers, The Stack Exchange Q&A Network, ...

The Tao of Twitter: Changing your life and business 140 characters at a time - Amazon
It's time to take the mystery out of Twitter. Twitter may be the most powerful business and personal networking platform ever created but it ...

App Store - Voices 2 ~ fun voice changing!
Read reviews, get customer ratings, see screenshots, and learn more about Voices 2 ~ fun voice changing! on the App Store. Download Voices 2 ...

Resources last updated: 12/31/2015 12:18:57 PM