i am trying to send a dynamic email through smtp in the code behind of one of my pages. when i try to run the app i get the follwing error
"The message could not be sent to the SMTP server. The transport error code was 0x800ccc69. The server response was 550 Invalid recipient: XXXXXX@hotmail.com"
also i am using an smtp server on my local machine so when i turn it on i get the above error, when i turn it off and run it i get the following error:
"The transport failed to connect to the server."
Does anyone have any idea how to fix this? here is my code behind
Partial Public Class _Default
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Dim result As String = ""
Dim sr As StreamReader = New StreamReader("MyContent.htm")
sr = File.OpenText("MyContent.htm")
result = sr.ReadToEnd()
Catch ex As Exception
Dim MessageBody As String = result.Replace("<YourFriendName>", txtFriendName.Text)
View Complete Post