Davidmc555
Programmer
I'm having a problem with a bit of code I'm writing. It's for email notification when an ASP.NET web app completes.
No shockers there, I'm sure you'll agree. During testing I sent the test emails to myself rather than the support group and got the following email.
"An activation has been generated for the following client.
Client ID = 1234
Client Name = Email Test UK
License Code = 1234-1234-1234-1234
Activation Code = 444444
Number of Users = 5"
That's fine, that's what I want. So I tried it with the other email address for support and got...
"An activation has been generated for the following client."
That's it. I've tried a number of things like replacing the string but it always has the same effect. Any clues as to where I'm going wrong?
Cheers in advance.
Code:
'Create an instance of the MailMessage class
'Set the properties
objMM.To = "support@mycompany.com"
'objMM.To = "david.mcgeown@mycompany.com"
objMM.From = "supportOZ@mycompany.com"
'Send the email in HTML format
objMM.BodyFormat = MailFormat.Text
'Set the priority
objMM.Priority = MailPriority.Normal
'Set the subject
objMM.Subject = "License and Activation for client"
'Set the body
strBody = "An activation has been generated for the following client." & (Chr(13)) & "Client ID = " & txtClientID.Text & (Chr(13)) & "Client Name = " & txtClientName.Text & (Chr(13)) & "License Code = " & txtLicenseKey.Text & (Chr(13)) & "Activation Code = " & txtActivKey.Text & (Chr(13)) & "Number of Users = " & ddlUsers.SelectedValue
objMM.Body = strBody
'Specify the Smtp Server
SmtpMail.SmtpServer = "mail.mycompany.com"
'send the message
SmtpMail.Send(objMM)
No shockers there, I'm sure you'll agree. During testing I sent the test emails to myself rather than the support group and got the following email.
"An activation has been generated for the following client.
Client ID = 1234
Client Name = Email Test UK
License Code = 1234-1234-1234-1234
Activation Code = 444444
Number of Users = 5"
That's fine, that's what I want. So I tried it with the other email address for support and got...
"An activation has been generated for the following client."
That's it. I've tried a number of things like replacing the string but it always has the same effect. Any clues as to where I'm going wrong?
Cheers in advance.