Home All Groups Group Topic Archive Search About

How to send email with no outlook and SMTP server ?

Author
26 Apr 2010 6:21 PM
fniles
Is there any way to send an email (either from a VB program or ASP or HTML)
if the machine has no Outlook and/or SMTP server ?
Thank you

Author
26 Apr 2010 6:30 PM
Cor Ligthert[MVP]
If they have not blocked it, you can sometimes use the smpt server from your
Internet provider.

Look first if there are regulations about that.


Show quoteHide quote
"fniles" <fni***@pfmail.com> wrote in message
news:#2DBO1W5KHA.620@TK2MSFTNGP02.phx.gbl...
> Is there any way to send an email (either from a VB program or ASP or
> HTML) if the machine has no Outlook and/or SMTP server ?
> Thank you
>
>
Author
26 Apr 2010 6:30 PM
Patrice
At some point you need a SMTP server. It could be an external server (for
example Gmail). Depending on what you are looking for you could also post to
a web server and this server could then get those date and send a mail...

Some more details about the overall situation could help.

--
Patrice

Show quoteHide quote
"fniles" <fni***@pfmail.com> a écrit dans le message de groupe de discussion
: #2DBO1W5KHA.***@TK2MSFTNGP02.phx.gbl...
> Is there any way to send an email (either from a VB program or ASP or
> HTML) if the machine has no Outlook and/or SMTP server ?
> Thank you
>
Author
27 Apr 2010 12:53 AM
C. Kevin Provance
"fniles" <fni***@pfmail.com> wrote in message news:%232DBO1W5KHA.620@TK2MSFTNGP02.phx.gbl...
: Is there any way to send an email (either from a VB program or ASP or HTML)
: if the machine has no Outlook and/or SMTP server ?
: Thank you

Is there a way to play a CD without a CD player?

There ya go.
Author
27 Apr 2010 4:18 AM
Bwig Zomberi
fniles wrote:
> Is there any way to send an email (either from a VB program or ASP or HTML)
> if the machine has no Outlook and/or SMTP server ?
> Thank you
>
>

If it is your local computer, then installing IIS will provide a local
SMTP server. If you hosting on a shared server, the hosting provider
would have already configured an SMTP server. In most cases, you
wouldn't have to specify an SMTP server address. You just need to simply
set the from and to addresses and call send.

--
  Bwig Zomberi
Author
27 Apr 2010 7:59 AM
Cor Ligthert[MVP]
Bwig,

Not on all OS versions

Show quoteHide quote
"Bwig Zomberi" <zomberiMAPSONNOSPAM@gmail.com> wrote in message
news:hr5ogn$1h6$1@speranza.aioe.org...
> fniles wrote:
>> Is there any way to send an email (either from a VB program or ASP or
>> HTML)
>> if the machine has no Outlook and/or SMTP server ?
>> Thank you
>>
>>
>
> If it is your local computer, then installing IIS will provide a local
> SMTP server. If you hosting on a shared server, the hosting provider would
> have already configured an SMTP server. In most cases, you wouldn't have
> to specify an SMTP server address. You just need to simply set the from
> and to addresses and call send.
>
> --
>  Bwig Zomberi
Author
28 Apr 2010 4:33 AM
Bwig Zomberi
Possibly. But most people develop scripts on an ordinary desktop and
upload to a shared hosting server. Most hosting providers configure an
SMTP server on the same web server so that script writers do not have to
explicitly specify an IP address.



Cor Ligthert[MVP] wrote:
Show quoteHide quote
> Bwig,
>
> Not on all OS versions
>
> "Bwig Zomberi" <zomberiMAPSONNOSPAM@gmail.com> wrote in message
> news:hr5ogn$1h6$1@speranza.aioe.org...
>> fniles wrote:
>>> Is there any way to send an email (either from a VB program or ASP or
>>> HTML)
>>> if the machine has no Outlook and/or SMTP server ?
>>> Thank you
>>>
>>>
>>
>> If it is your local computer, then installing IIS will provide a local
>> SMTP server. If you hosting on a shared server, the hosting provider
>> would have already configured an SMTP server. In most cases, you
>> wouldn't have to specify an SMTP server address. You just need to
>> simply set the from and to addresses and call send.
>>
>> --
>> Bwig Zomberi
>


--
  Bwig Zomberi
Author
27 Apr 2010 6:58 AM
David Kaye
"fniles" <fni***@pfmail.com> wrote:
>Is there any way to send an email (either from a VB program or ASP or HTML)
>if the machine has no Outlook and/or SMTP server ?
>Thank you

Do I smell somebody trying to write malware here?  Sure seems like it to me.
Author
27 Apr 2010 1:34 PM
Mayayana
| >Is there any way to send an email (either from a VB program or ASP or
HTML)
| >if the machine has no Outlook and/or SMTP server ?
| >Thank you
|
| Do I smell somebody trying to write malware here?  Sure seems like it to
me.
|

  What if I asked for advice on buying a
portable power drill? Would you assume
that I wanted it for burglaries?

   There are lots of reasons to want to send
email, from a PC or a website, and no reason
that anyone should be reduced to using a
method as hokey as Outlook automation or MAPI.
(Contrary to the .Net philosophy, "the more
wrappers the better" is not necessarily true. :)
Author
27 Apr 2010 12:55 PM
Mayayana
| Is there any way to send an email (either from a VB program or ASP or
HTML)
| if the machine has no Outlook and/or SMTP server ?
| Thank you
|

First you need to understand what VB is. You posted
to both the VB group and the VB.Net group.
Is what you really want VB.Net?

   Are you sure you know what an SMTP server is?
It's not the email sender. Sending email involves
contacting an SMTP server computer, or setting up
SMTP on your own server. Outlook is not the server,
it's just the sender. The sender carries out a
text-based "conversation" with the server. It's relatively
easy to do but you need to know the details of the
conversation.

   Viruses, of course, often incorporate their own
SMTP functionality, but that's probably not a feasible
method anymore. Many ISPs will block unrecognized
SMTP sources.

  I have VB code for sending email, with no dependencies,
which automatically deals with a PLAIN or LOGIN password
scenario. (For most ISPs that's sufficient. But in some
situations you might run into other complications. For
instance, GMail webmail requires a secure connection. And
in rare cases, like maybe a government server, you might
need password encryption.)
  There are also free controls available. (Ex.: vbSendMail)

So if it's VB you want and you don't need specialized
functionality, then it's free and easy to cut the dependency
on Outlook, MAPI, or any other email program.

  If you need VB.Net code...I have no idea. One would
hope that it's somewhere in that 300+MB of runtime
baggage, without needing to install Outlook.

  If you need to do this from a webpage that's an entirely
different situation. And it's different again for ASP (Windows)
vs Unix/Linux (where you can get free PHP scripts, or get
a pre-set-up package from your web host).

  So, yes, you can send email. But you should really
understand how it works, and also check into the ISP
you intend to use. And it would help if you explain
exactly what situation/tools you're dealing with.
Author
27 Apr 2010 4:27 PM
Tom Shelton
On 2010-04-27, Mayayana <mayayana@invalid.nospam> wrote:
>
>| Is there any way to send an email (either from a VB program or ASP or
> HTML)
>| if the machine has no Outlook and/or SMTP server ?
>| Thank you
>|

<SNIP>

>   If you need VB.Net code...I have no idea. One would
> hope that it's somewhere in that 300+MB of runtime
> baggage, without needing to install Outlook.

Option Strict On
Option Explicit On

Imports System
Imports System.Net
Imports System.Net.Mail

Module Module1

    Sub Main()
        Using msg As New MailMessage

            With msg
                .From = New MailAddress("someb***@someplace.com")
                .To.Add(New MailAddress("someotherb***@someotherplace.com"))
                .Subject = "some subject"
                .Body = "Hey there!"
            End With

            Dim smtp As New SmtpClient("my.mail.server.net")
            ' assuming your server requires authentication...
            smtp.Credentials = New NetworkCredential("myusername", "mypassword")
            smtp.Send(msg)

        End Using
    End Sub

End Module


--
Tom Shelton
Author
27 Apr 2010 1:44 PM
Jeff Johnson
"fniles" <fni***@pfmail.com> wrote in message
news:%232DBO1W5KHA.620@TK2MSFTNGP02.phx.gbl...

> Is there any way to send an email (either from a VB program or ASP or
> HTML) if the machine has no Outlook and/or SMTP server ?

Here's how I read his post, folks. Perhaps my interpretation is wrong.

"Is it possible to send email without using a mail client such as Outlook
and without having an SMTP server installed LOCALLY?"

The answer: OF COURSE IT IS. Tons of people send email every day in these
very situations. All that's needed is to connect to a REMOTE SMTP server. I
don't believe he was asking if it's possible to send email without an SMTP
sever involved AT SOME POINT.

The answer is "do a Google search," because this question has been asked and
answered over and over.
Author
27 Apr 2010 6:35 PM
Michel Posseth [MCP]
I once wrote a VB6 catalogue program that had the ability to place orders
that had to be send to a e-mail adress of a reseller
after strugling with lots of methods ( registry etc etc ) to get the local
SMTP server and at one point running into a big problem where the users had
a Lotus Domino system i found out that it was much easier to send a form
posting over HTTP to a server that i controled and generate the e-mail from
there
to be send to the order department of the company where i wrote the program
for .

I then only needed the local email adress so the order department could
optionally reply to the placed order

Hope this helps

Michel



Show quoteHide quote
"fniles" <fni***@pfmail.com> schreef in bericht
news:%232DBO1W5KHA.620@TK2MSFTNGP02.phx.gbl...
> Is there any way to send an email (either from a VB program or ASP or
> HTML) if the machine has no Outlook and/or SMTP server ?
> Thank you
>
Author
27 Apr 2010 7:01 PM
Tom Shelton
On 2010-04-27, Michel Posseth [MCP] <m***@posseth.com> wrote:
Show quoteHide quote
>
> I once wrote a VB6 catalogue program that had the ability to place orders
> that had to be send to a e-mail adress of a reseller
> after strugling with lots of methods ( registry etc etc ) to get the local
> SMTP server and at one point running into a big problem where the users had
> a Lotus Domino system i found out that it was much easier to send a form
> posting over HTTP to a server that i controled and generate the e-mail from
> there
> to be send to the order department of the company where i wrote the program
> for .
>
> I then only needed the local email adress so the order department could
> optionally reply to the placed order
>
> Hope this helps
>
> Michel
>

I could see that in the old days - but, really how many companies don't have
email now a days?  Even a small company is going to have an email account -
all you need to know is the server address and the login info to send an
email.  smtp is a very simple protocol.

--
Tom Shelton
Author
27 Apr 2010 8:10 PM
Michel Posseth [MCP]
Well the program i wrote was installed from a cd-rom ( DVD in a later
stage ) and had to function "out of the box"
and i bet not a lot of people ( end consumers ) know there e-mail settings
so i guess the same aplies as of today

Also you forget about the Lotus Domino  situation or if there is a Outlook
server installed on a company network
( for a fact i never got Lotus to work )

So in these sitautions my solution was / is  just fool proof and verry
simple to implement

>smtp is a very simple protocol.

For VB6 i used the VBSendmail.dll and in .Net you can just use the builtin
framework classes however they are perfect in a "simple" situation
even on a MS Exchange network it will not work if SMTP is closed on the mail
server ( this is default on Exchange )  , for a fact in the company i
currently work for we have a Linux mail server especially for our .Net apps
as the admins want to keep the "recomended" settings on the Exchange server
..


regards

Michel




Show quoteHide quote
"Tom Shelton" <tom_shel***@comcastXXXXXXX.net> schreef in bericht
news:%23MfI%23vj5KHA.5464@TK2MSFTNGP05.phx.gbl...
> On 2010-04-27, Michel Posseth [MCP] <m***@posseth.com> wrote:
>>
>> I once wrote a VB6 catalogue program that had the ability to place orders
>> that had to be send to a e-mail adress of a reseller
>> after strugling with lots of methods ( registry etc etc ) to get the
>> local
>> SMTP server and at one point running into a big problem where the users
>> had
>> a Lotus Domino system i found out that it was much easier to send a form
>> posting over HTTP to a server that i controled and generate the e-mail
>> from
>> there
>> to be send to the order department of the company where i wrote the
>> program
>> for .
>>
>> I then only needed the local email adress so the order department could
>> optionally reply to the placed order
>>
>> Hope this helps
>>
>> Michel
>>
>
> I could see that in the old days - but, really how many companies don't
> have
> email now a days?  Even a small company is going to have an email
> account -
> all you need to know is the server address and the login info to send an
> email.  smtp is a very simple protocol.
>
> --
> Tom Shelton
Author
27 Apr 2010 8:56 PM
Tom Shelton
On 2010-04-27, Michel Posseth [MCP] <m***@posseth.com> wrote:
>
> Well the program i wrote was installed from a cd-rom ( DVD in a later
> stage ) and had to function "out of the box"
> and i bet not a lot of people ( end consumers ) know there e-mail settings
> so i guess the same aplies as of today
>

And yet, they manage to get their outlook working...  I'm willing to bet that
the guy that installs the software also knows the corporate email settings.
But, you know your users.  Your way probably was best for  your situation.

Show quoteHide quote
> Also you forget about the Lotus Domino  situation or if there is a Outlook
> server installed on a company network
> ( for a fact i never got Lotus to work )
>
> So in these sitautions my solution was / is  just fool proof and verry
> simple to implement
>
>>smtp is a very simple protocol.
>
> For VB6 i used the VBSendmail.dll and in .Net you can just use the builtin
> framework classes however they are perfect in a "simple" situation
> even on a MS Exchange network it will not work if SMTP is closed on the mail
> server ( this is default on Exchange )  , for a fact in the company i
> currently work for we have a Linux mail server especially for our .Net apps
> as the admins want to keep the "recomended" settings on the Exchange server
> .
>

Hmmm... That's interesting.  Not having ever done anything with Exchange
admin, I know nothing about setting it up or configuring it.  Or what is
recommended best practice or not.  But, I know on every corporate exchange
network I have been on, I have no problems sending emails using the smtp
classes in .NET as long as I set the authentication properly...

--
Tom Shelton
Author
27 Apr 2010 9:39 PM
Helmut Meukel
Show quote Hide quote
>> For VB6 i used the VBSendmail.dll and in .Net you can just use the builtin
>> framework classes however they are perfect in a "simple" situation
>> even on a MS Exchange network it will not work if SMTP is closed on the mail
>> server ( this is default on Exchange )  , for a fact in the company i
>> currently work for we have a Linux mail server especially for our .Net apps
>> as the admins want to keep the "recomended" settings on the Exchange server
>> .
>>
>
> Hmmm... That's interesting.  Not having ever done anything with Exchange
> admin, I know nothing about setting it up or configuring it.  Or what is
> recommended best practice or not.  But, I know on every corporate exchange
> network I have been on, I have no problems sending emails using the smtp
> classes in .NET as long as I set the authentication properly...
>


I gave up trying to understand what happens in the heads of IT admins.
Just yesterday I sent an update of my app to my customer - appended to an
email. This time I sent it to his private email address, not his company email
account.
Last time I had to send it twice, the exe was stripped from my email and after
hours trying to get it released from the IT he phoned me to send it to his
private
email account. There he _could_ download the exe to his company PC!
Funny how they have secured their company net, isn't it?

Helmut.
Author
28 Apr 2010 9:44 AM
Cor Ligthert[MVP]
Helmut,

Default behaviour, exe's don't go trhough almost through not any mailserver
anymore.

The admins don't do that, they simply install the latest updates.

They have to do something extra to remove that, and who will do that as that
can be a reason for a complete company going down, they will be direct
fired, whatever they complain and right they have.

Cor

Show quoteHide quote
"Helmut Meukel" <NoSpam@NoProvider.de> wrote in message
news:excTnIl5KHA.1932@TK2MSFTNGP05.phx.gbl...
>>> For VB6 i used the VBSendmail.dll and in .Net you can just use the
>>> builtin
>>> framework classes however they are perfect in a "simple" situation
>>> even on a MS Exchange network it will not work if SMTP is closed on the
>>> mail
>>> server ( this is default on Exchange )  , for a fact in the company i
>>> currently work for we have a Linux mail server especially for our .Net
>>> apps
>>> as the admins want to keep the "recomended" settings on the Exchange
>>> server
>>> .
>>>
>>
>> Hmmm... That's interesting.  Not having ever done anything with Exchange
>> admin, I know nothing about setting it up or configuring it.  Or what is
>> recommended best practice or not.  But, I know on every corporate
>> exchange
>> network I have been on, I have no problems sending emails using the smtp
>> classes in .NET as long as I set the authentication properly...
>>
>
>
> I gave up trying to understand what happens in the heads of IT admins.
> Just yesterday I sent an update of my app to my customer - appended to an
> email. This time I sent it to his private email address, not his company
> email
> account.
> Last time I had to send it twice, the exe was stripped from my email and
> after
> hours trying to get it released from the IT he phoned me to send it to his
> private
> email account. There he _could_ download the exe to his company PC!
> Funny how they have secured their company net, isn't it?
>
> Helmut.
>
Author
28 Apr 2010 1:33 PM
Dee Earley
On 28/04/2010 10:44, Cor Ligthert[MVP] wrote:
> Helmut,
>
> Default behaviour, exe's don't go trhough almost through not any
> mailserver anymore.

Mailservers do not change the mail.
They MAY defer to filters to do this, but I've not seen any mainstream
MTAs that block these by default out of the box.

After all, that is not their job...

--
Dee Earley (dee.ear***@icode.co.uk)
i-Catcher Development Team

iCode Systems

(Replies direct to my email address will be ignored.
Please reply to the group.)
Author
28 Apr 2010 2:06 PM
Jeff Johnson
"Dee Earley" <dee.ear***@icode.co.uk> wrote in message
news:uH3Acdt5KHA.1932@TK2MSFTNGP05.phx.gbl...

>> Default behaviour, exe's don't go trhough almost through not any
>> mailserver anymore.
>
> Mailservers do not change the mail.

Well, you know, other than maybe inserting a Received header....
Author
28 Apr 2010 2:42 PM
H-Man
On Tue, 27 Apr 2010 23:39:40 +0200, Helmut Meukel wrote:

Show quoteHide quote
>>> For VB6 i used the VBSendmail.dll and in .Net you can just use the builtin
>>> framework classes however they are perfect in a "simple" situation
>>> even on a MS Exchange network it will not work if SMTP is closed on the mail
>>> server ( this is default on Exchange )  , for a fact in the company i
>>> currently work for we have a Linux mail server especially for our .Net apps
>>> as the admins want to keep the "recomended" settings on the Exchange server
>>> .
>>>
>>
>> Hmmm... That's interesting.  Not having ever done anything with Exchange
>> admin, I know nothing about setting it up or configuring it.  Or what is
>> recommended best practice or not.  But, I know on every corporate exchange
>> network I have been on, I have no problems sending emails using the smtp
>> classes in .NET as long as I set the authentication properly...
>>
>
>
> I gave up trying to understand what happens in the heads of IT admins.
> Just yesterday I sent an update of my app to my customer - appended to an
> email. This time I sent it to his private email address, not his company email
> account.
> Last time I had to send it twice, the exe was stripped from my email and after
> hours trying to get it released from the IT he phoned me to send it to his
> private
> email account. There he _could_ download the exe to his company PC!
> Funny how they have secured their company net, isn't it?
>
> Helmut.

Some of the ways I've gotten around this;
1) simply change the extension to something like .ABC. In the body of the
email the recipient is instructed to rename the file back to .EXE.
2) send in a packed format ie. .ZIP or .7z or something like that.
3) password protect the packed file. sometimes this will go through if
their email AV finds a false positive.


--
HK
Author
28 Apr 2010 6:57 PM
Karl E. Peterson
H-Man wrote:
> Some of the ways I've gotten around this;
> 1) simply change the extension to something like .ABC. In the body of the
> email the recipient is instructed to rename the file back to .EXE.
> 2) send in a packed format ie. .ZIP or .7z or something like that.
> 3) password protect the packed file. sometimes this will go through if
> their email AV finds a false positive.

Lots of servers look into ZIPs (passworded or not) for EXEs (and other
executable extensions) now, and filter based strictly on that.  I've
associated the XIP extension on my machine to operate identically to
ZIP, and this eases that pain for me just a bit as I routinely need to
send/recieve zipped executables.  :-)

--
..NET: It's About Trust!
http://vfred.mvps.org
Author
29 Apr 2010 5:07 AM
Michel Posseth [MCP]
Show quote Hide quote
"Helmut Meukel" <NoSpam@NoProvider.de> schreef in bericht
news:excTnIl5KHA.1932@TK2MSFTNGP05.phx.gbl...
>>> For VB6 i used the VBSendmail.dll and in .Net you can just use the
>>> builtin
>>> framework classes however they are perfect in a "simple" situation
>>> even on a MS Exchange network it will not work if SMTP is closed on the
>>> mail
>>> server ( this is default on Exchange )  , for a fact in the company i
>>> currently work for we have a Linux mail server especially for our .Net
>>> apps
>>> as the admins want to keep the "recomended" settings on the Exchange
>>> server
>>> .
>>>
>>
>> Hmmm... That's interesting.  Not having ever done anything with Exchange
>> admin, I know nothing about setting it up or configuring it.  Or what is
>> recommended best practice or not.  But, I know on every corporate
>> exchange
>> network I have been on, I have no problems sending emails using the smtp
>> classes in .NET as long as I set the authentication properly...
>>
>
>
> I gave up trying to understand what happens in the heads of IT admins.
> Just yesterday I sent an update of my app to my customer - appended to an
> email. This time I sent it to his private email address, not his company
> email
> account.
> Last time I had to send it twice, the exe was stripped from my email and
> after
> hours trying to get it released from the IT he phoned me to send it to his
> private
> email account. There he _could_ download the exe to his company PC!
> Funny how they have secured their company net, isn't it?
>
> Helmut.

Helmut

I know exactly  what you are dealing with , even zipping the file and deploy
it as an archive gets the file stripped from it here at my company
that is why i favor Winrar  as my favorite archive tool ( for some weird
reason the RAR extension seems to be more safe ? ;-) )
also a good trick is to just rename foo.dll or foo.exe to  foo.dl_ or
foo.ex_ with instructions for the receiver to rename the file in the mail
message

regards

Michel