ASPmail

S

Steve Bywaters

Since 2000, I have built a web site for a client in ASP, using CDO mail.
All has been well, and I have getting extension projects from them <g>

But while I was away on the holiday over Christmas, the "IT dept." has
decided to rationalise all the web servers (ok)... and standardise on one
mail component (ok)... and they have chosen and bought ASPmail (huh?)
without consultation with me. This will break a lot of my code (syntax is
very different)... and a junior in-house developer has been assigned the
task of making my site work with the changes. he is struggling, not knowing
my application very well, and it will take him a lot of time....

Hmmm....Is this a bid for *control* by the pointy-heads.. or does ASPmail
really have some good stuff going for it?

Interested in views...
Steve
 
A

Aaron Bertrand [MVP]

without consultation with me. This will break a lot of my code (syntax is
very different).

Sounds like a great opportunity to do what you should have done back then,
and encapsulate the code into a function in a common include. Then the
inidividual ASP pages only have to have:

call mail(to, from, subject, body)

And when the company changes mail components, or changes their SMTP server,
or requires outgoing authentication, you only have to change one file.
 
S

Steve Bywaters

Always greateful for hints on how to program...
.... but you didn't address my main question (ie does ASPmail have some real
advantages?)
 
B

Brynn

I agree ... I have one subroutine that accepts to, from, subject, and
body ... the 'to' is setup to accept ...

to,[email protected]*m,TheirName;to,[email protected]*m;cc,[email protected]*m,TheirName

And yes, the name is optional ... as you can see in the string above

I have ASPEmail on my server, and my subroutine looks like this ...


<%
'// EXAMPLE SUBROUTINE CALL
'// Call cp_ASPEmail_Sender("(e-mail address removed)",
"to,[email protected],Brynn;cc,[email protected]", "The Subject",
"The Body")

'// EMAIL SERVER
Dim cp_MailHost: cp_MailHost = "mail.coolpier.com"

Sub cp_ASPEmail_Sender(cp_From, cp_To, cp_Subject, cp_Body)
Set cp_ASPEmail_Obj = CreateObject("Persits.MailSender")
With cp_ASPEmail_Obj
.Host = cp_MailHost

'// EMAIL ADDRESSES
Dim cp_n, cp_AddressArray, cp_ToArray
'// FROM
cp_AddressArray = Split(cp_From, ",")
.From = cp_AddressArray(0): .FromName =
cp_AddressArray(ubound(cp_AddressArray))
'// TO
cp_ToArray = Split(cp_To, ";")
For cp_n = 0 to ubound(cp_ToArray)
cp_AddressArray =
Split(cp_ToArray(cp_n), ",")
Select Case cp_AddressArray(0)
Case "to"
.AddAddress
cp_AddressArray(1), cp_AddressArray(ubound(cp_AddressArray))
Case "cc"
.AddCC
cp_AddressArray(1), cp_AddressArray(ubound(cp_AddressArray))
Case "bcc"
.AddBcc
cp_AddressArray(1), cp_AddressArray(ubound(cp_AddressArray))
End Select
Next

'// EMAIL SUBJECT & BODY
.Subject = cp_Subject
.Body = cp_Body

'// SEND EMAIL
strErr = "": bSuccess = False
On Error Resume Next
.Send
If Err <> 0 Then: strErr = Err.Description:
Else: bSuccess = True: End If
End With
End Sub
%>



Brynn
www.coolpier.com


Sounds like a great opportunity to do what you should have done back then,
and encapsulate the code into a function in a common include. Then the
inidividual ASP pages only have to have:

call mail(to, from, subject, body)

And when the company changes mail components, or changes their SMTP server,
or requires outgoing authentication, you only have to change one file.

I participate in the group to help give examples of code. I do not guarantee the effects of any code posted. Test all code before use!

Brynn
www.coolpier.com
 
B

Brynn

In fact Aaron ... you know if Persists has any issues with me posting
a sample like that subroutine on my site?

Brynn


Sounds like a great opportunity to do what you should have done back then,
and encapsulate the code into a function in a common include. Then the
inidividual ASP pages only have to have:

call mail(to, from, subject, body)

And when the company changes mail components, or changes their SMTP server,
or requires outgoing authentication, you only have to change one file.

I participate in the group to help give examples of code. I do not guarantee the effects of any code posted. Test all code before use!

Brynn
www.coolpier.com
 
R

Roland Hall

:
: Always greateful for hints on how to program...
: ... but you didn't address my main question (ie does ASPmail have some
real
: advantages?)

He eluded that it did, however you can read for yourself.

http://www.serverobjects.com/products.htm#aspmail

--
Roland

This information is distributed in the hope that it will be useful, but
without any warranty; without even the implied warranty of merchantability
or fitness for a particular purpose.
-Technet Knowledge Base-
http://support.microsoft.com/default.aspx?scid=fh;EN-US;kbhowto&sd=TECH&ln=EN-US&FR=0
-Technet Script Center-
http://www.microsoft.com/technet/treeview/default.asp?url=/technet/scriptcenter/default.asp
-WSH 5.6 documentation download-
http://www.microsoft.com/downloads/...48-207D-4BE1-8A76-1C4099D7BBB9&displaylang=en
-MSDN Library-
http://msdn.microsoft.com/library/default.asp
 
R

Roland Hall

:
: I have ASPEmail on my server, and my subroutine looks like this ...

Ok, but he said, "ASPmail". (see Subject) (O:=

ASPMail is ServerObjects'.
http://www.serverobjects.com/products.htm#aspmail

ASPEmail is Persits'.
http://www.aspemail.com/

--
Roland

This information is distributed in the hope that it will be useful, but
without any warranty; without even the implied warranty of merchantability
or fitness for a particular purpose.
-Technet Knowledge Base-
http://support.microsoft.com/default.aspx?scid=fh;EN-US;kbhowto&sd=TECH&ln=EN-US&FR=0
-Technet Script Center-
http://www.microsoft.com/technet/treeview/default.asp?url=/technet/scriptcenter/default.asp
-WSH 5.6 documentation download-
http://www.microsoft.com/downloads/...48-207D-4BE1-8A76-1C4099D7BBB9&displaylang=en
-MSDN Library-
http://msdn.microsoft.com/library/default.asp
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,540
Members
45,025
Latest member
KetoRushACVFitness

Latest Threads

Top