Click here to Skip to main content
15,923,006 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionGridView - PageIndexChanging not handled Pin
MarkMokris7-May-09 8:51
MarkMokris7-May-09 8:51 
AnswerRe: GridView - PageIndexChanging not handled Pin
SayreCC7-May-09 14:39
SayreCC7-May-09 14:39 
AnswerRe: GridView - PageIndexChanging not handled Pin
Perry Holman7-May-09 23:32
Perry Holman7-May-09 23:32 
Questionhow we create autogenerated textbox in gridview Pin
rummer7-May-09 8:08
rummer7-May-09 8:08 
AnswerRe: how we create autogenerated textbox in gridview Pin
EssamDev7-May-09 13:52
EssamDev7-May-09 13:52 
Questioncode for a multiline textbox Pin
rummer7-May-09 8:05
rummer7-May-09 8:05 
AnswerRe: code for a multiline textbox Pin
Christian Graus7-May-09 11:49
protectorChristian Graus7-May-09 11:49 
Questionerror on sending mail Pin
Any_India7-May-09 5:39
Any_India7-May-09 5:39 
Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
' System.Web.Mail.SmtpMail.SmtpServer is obsolete in 2.0
' System.Net.Mail.SmtpClient is the alternate class for this in 2.0
Dim smtpClient As New SmtpClient()
Dim message As New MailMessage()

Try
Dim fromAddress As New MailAddress(txtEmail.Text, txtName.Text)

' You can specify the host name or ipaddress of your server
' Default in IIS will be localhost
smtpClient.Host = "localhost"

'Default port will be 25
smtpClient.Port = 25

'From address will be given as a MailAddress Object
message.From = fromAddress

' To address collection of MailAddress
message.[To].Add("anup2005debnath@gmail.com")
message.Subject = "Feedback"

' CC and BCC optional
' MailAddressCollection class is used to send the email to various users
' You can specify Address as new MailAddress("admin1@yoursite.com")
message.CC.Add("anup2005debnath@gmail.com")
message.CC.Add("anup2005debnath@gmail.com")

' You can specify Address directly as string
message.Bcc.Add(New MailAddress("anup2005debnath@gmail.com"))
message.Bcc.Add(New MailAddress("anup2005debnath@gmail.com"))

'Body can be Html or text format
'Specify true if it is html message
message.IsBodyHtml = False

' Message body content
message.Body = txtMessage.Text

' Send SMTP mail
smtpClient.Send(message)

lblStatus.Text = "Email successfully sent."
Catch ex As Exception
lblStatus.Text = "Send Email Failed." & ex.Message
End Try



i got error "failed to send message" plz solve the problem
AnswerRe: error on sending mail Pin
I am BATMAN7-May-09 7:13
I am BATMAN7-May-09 7:13 
GeneralRe: error on sending mail Pin
Any_India7-May-09 20:07
Any_India7-May-09 20:07 
AnswerRe: error on sending mail Pin
Abhijit Jana7-May-09 7:41
professionalAbhijit Jana7-May-09 7:41 
AnswerRe: error on sending mail Pin
Perry Holman7-May-09 23:41
Perry Holman7-May-09 23:41 
QuestionUpdating comfirmation box by commandfield. Pin
magshine7-May-09 5:22
magshine7-May-09 5:22 
QuestionLiveUI 0.4 released (Extjs => ASP.net bridge) Your opinion? Pin
Alexandr Sergeevich Ilyin7-May-09 5:03
Alexandr Sergeevich Ilyin7-May-09 5:03 
AnswerRe: LiveUI 0.4 released (Extjs => ASP.net bridge) Your opinion? Pin
ToddHileHoffer7-May-09 8:34
ToddHileHoffer7-May-09 8:34 
GeneralRe: LiveUI 0.4 released (Extjs => ASP.net bridge) Your opinion? Pin
Alexandr Sergeevich Ilyin7-May-09 21:29
Alexandr Sergeevich Ilyin7-May-09 21:29 
AnswerRe: LiveUI 0.4 released (Extjs => ASP.net bridge) Your opinion? Pin
Vasudevan Deepak Kumar7-May-09 22:10
Vasudevan Deepak Kumar7-May-09 22:10 
GeneralRe: LiveUI 0.4 released (Extjs => ASP.net bridge) Your opinion? Pin
Alexandr Sergeevich Ilyin7-May-09 22:44
Alexandr Sergeevich Ilyin7-May-09 22:44 
QuestionUpdate panel with response.write Pin
mahesvs7-May-09 4:48
mahesvs7-May-09 4:48 
GeneralWebsite Application Deployment Issue Pin
newc17-May-09 3:55
newc17-May-09 3:55 
GeneralRe: Website Application Deployment Issue Pin
Abhijit Jana7-May-09 19:13
professionalAbhijit Jana7-May-09 19:13 
GeneralRe: Website Application Deployment Issue Pin
newc17-May-09 22:30
newc17-May-09 22:30 
Questionconnection string Pin
vnsraj7-May-09 2:55
vnsraj7-May-09 2:55 
AnswerRe: connection string Pin
Yusuf7-May-09 3:00
Yusuf7-May-09 3:00 
GeneralRe: connection string Pin
vnsraj7-May-09 3:14
vnsraj7-May-09 3:14 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.