P
Paco
I'm having a problem with an ASP page I've made and was hoping someone
out there can help.
My page sends an email using CDO to a username pulled from a database
as follows:
With cdoMessage
Set .Configuration = cdoConfig
.From = "Admin <[email protected]>"
.To = rs("USERName") & "@MyCompany.com"
.Subject = "Notification #" & rs("subject_Num")
.TextBody = txtVar
.Send
End With
this works great so long as USERName isn't garbage. If there are bad
characters in it that IIS doesn't like, it get an error '8004020f' at
the .send line. I was wondering if there was an easy and / or
publicly available code snippet that could check the user name for
special chars. Ideally, it would email me if there was a problem with
the USERName rather than just strip the bad chars out and send it to
whatever is left.
Any help pointing me in the right direction would be greatly
appreciated.
Paco
out there can help.
My page sends an email using CDO to a username pulled from a database
as follows:
With cdoMessage
Set .Configuration = cdoConfig
.From = "Admin <[email protected]>"
.To = rs("USERName") & "@MyCompany.com"
.Subject = "Notification #" & rs("subject_Num")
.TextBody = txtVar
.Send
End With
this works great so long as USERName isn't garbage. If there are bad
characters in it that IIS doesn't like, it get an error '8004020f' at
the .send line. I was wondering if there was an easy and / or
publicly available code snippet that could check the user name for
special chars. Ideally, it would email me if there was a problem with
the USERName rather than just strip the bad chars out and send it to
whatever is left.
Any help pointing me in the right direction would be greatly
appreciated.
Paco