472,805 Members | 755 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,805 software developers and data experts.

Send email while knowing nothing

I want to send a bug report automatically from my VB.NET program. I won't
know the end user's smtp server or what email client they are using.

The Process.Start with mailto is almost what I need, but the amount of
information that will fit in the body is too small for a stack dump and other
information.

I like the way that it would go into the outbox, but oh well, have to move on.

My next choice is Indy or System.Web.Mail, but I don't know their SMTP server.

Can I get it from the registry or some other method? How do programs that
allow me to register for support from email do it? Do they access their own
SMTP servers?
Nov 21 '05 #1
10 1541
John,

If this is about a user using your program on his computer than this is in
my opinion a kind of hacking if the user is not attended first and has the
right to deny that message.

If it is about a webapplication working on your server, than you can sent it
from that server.

I hope this helps,

Cor
Nov 21 '05 #2
Hello John
I was in a simular situation as you are right now ( only with a VB6
project ) i wanted to send some reports to our product manageres when the
items in our catalogue were wrong.

first i shelled out to the local installed e-mail client , then i used the
freevbcode`s vbsendmail.dll they worked both but as always both with there
flaws
( not working with outloook , Domino , sealed networks etc etc etc )

then i found the perfect solution : :-)

i wrote a webservice ( and webpage as a wrapper for my vb6 prog ) that
performs the sending of the e-mail , so i post ther required values to my
webservice the webservice creates a nice HTML formatted e-mail and sends it
from the webserver to the endpoint .

with this method the end user does not even need to have an e-mail account
to send mails to our product management
if you want more info feel free to ask
regards

Michel Posseth
"John Davies" <Jo********@discussions.microsoft.com> schreef in bericht
news:1C**********************************@microsof t.com...
I want to send a bug report automatically from my VB.NET program. I won't
know the end user's smtp server or what email client they are using.

The Process.Start with mailto is almost what I need, but the amount of
information that will fit in the body is too small for a stack dump and
other
information.

I like the way that it would go into the outbox, but oh well, have to move
on.

My next choice is Indy or System.Web.Mail, but I don't know their SMTP
server.

Can I get it from the registry or some other method? How do programs that
allow me to register for support from email do it? Do they access their
own
SMTP servers?

Nov 21 '05 #3
Michael,

With one disadvantage, the user should not be behind a firewall and be on
line.

In my opinion is needed a privaty statement as well, I am not sure if this
what you do is allowed by all laws (if it is not explicitly known by the
user).

What is in your case of course not the situation because it is a kind of
internal application.

Cor
Nov 21 '05 #4
> My next choice is Indy or System.Web.Mail, but I don't know their SMTP
server.

I have had success with this:

System.Web.Mail.SmtpMail.Send( _
Nothing, "to address goes here", "subject", "multiline body")

From address is Nothing.
System.Web.Mail.SmtpMail.SmtpServer is blank (untouched by my code).

On Windows XP systems, it seems to figure everything out, and the email
arrives from the default email account of the machine running the program.
No guarantees for other environments, but it sounds like an easy experiment
to try in your environment.

Nov 21 '05 #5
That's why I liked the mailto option so much. They could see exactly what was
being sent.

Since I couldn't do that, I was going to put up a dialog box for them to see
what was being sent and allow them to add a note. I was also planning on
having a Send and Cancel button.

I wouldn't like a program sending email behind my back either. But I like
the idea that bugs are easily reported.
Nov 21 '05 #6
That sounds really good. I like the idea of XP figuring it out for me.
Nov 21 '05 #7
John,
That's why I liked the mailto option so much. They could see exactly what
was
being sent.

Since I couldn't do that, I was going to put up a dialog box for them to
see
what was being sent and allow them to add a note. I was also planning on
having a Send and Cancel button.

I wouldn't like a program sending email behind my back either. But I like
the idea that bugs are easily reported.


I think that a combination of this with a webservice as Michael suggest is
one of the best things you can do. You can than let them type in their
emailaddress or references you have already in your program and let them
self push a sent and make the connection if needed.

Creating a webservice for this is in my opinion a piece of cake with VBNet.

Just store the message in a file or better in a Database on your server.

I hope this helps,

Cor
Nov 21 '05 #8
John,
That sounds really good. I like the idea of XP figuring it out for me.


Be aware that this only works on workstations with NT5 or newer NT.

If you have an open mailserver of your own, you can use that, if you use
withouth permission one of somebody else than it is AFAIK really a kind of
hard way hacking.

Just my thought,

Cor
Nov 21 '05 #9

Hello Cor ,
With one disadvantage, the user should not be behind a firewall and be on
line.
Well if they are not online and have RAS configured i connect for them

A firewall is no problem as i do a posting with my VB6 program to a aspx
page with the webbrowser control ( port 80 is always open on a firewall
-) ) then the server takes care of the rest
only the local software firewall on the users computer might complain that a
program wants to access the internet however in my situation this is already
allowed because of the auto update feature

In my opinion is needed a privaty statement as well, I am not sure if this
what you do is allowed by all laws (if it is not explicitly known by the
user).
It is known by the user as he is the one pressing the button to send the
complaint or question to product management

regards

Michel
"Cor Ligthert [MVP]" <no************@planet.nl> wrote in message
news:%2***************@TK2MSFTNGP15.phx.gbl... Michael,

With one disadvantage, the user should not be behind a firewall and be on
line.

In my opinion is needed a privaty statement as well, I am not sure if this
what you do is allowed by all laws (if it is not explicitly known by the
user).

What is in your case of course not the situation because it is a kind of
internal application.

Cor

Nov 21 '05 #10
John,
In addition to the other comments.

I normally store the SMTP server's name in the app.config file. Then set the
app.config during install of the app.

Be careful with using a blank SmtpServer property. It indicates to use
"local SMTP server", which I understand to mean localhost.

http://msdn.microsoft.com/library/de...ervertopic.asp

Localhost may not be installed or configured to send SMTP mail to the
correct server. I know some corporations don't install this component as it
was an easy way to send viruses... Plus some firewalls & ISPs place
restrictions on who's port 25 you can connect to.

If your "local SMTP server" is configured properly, your firewall allows it,
and your ISP allows it, then I agree a blank SmtpServer is the way to go...

The following site is an excellent resource on System.Web.Mail:

http://www.systemwebmail.net/

Hope this helps
Jay

"John Davies" <Jo********@discussions.microsoft.com> wrote in message
news:1C**********************************@microsof t.com...
|I want to send a bug report automatically from my VB.NET program. I won't
| know the end user's smtp server or what email client they are using.
|
| The Process.Start with mailto is almost what I need, but the amount of
| information that will fit in the body is too small for a stack dump and
other
| information.
|
| I like the way that it would go into the outbox, but oh well, have to move
on.
|
| My next choice is Indy or System.Web.Mail, but I don't know their SMTP
server.
|
| Can I get it from the registry or some other method? How do programs that
| allow me to register for support from email do it? Do they access their
own
| SMTP servers?
|
|
Nov 21 '05 #11

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Salim Afþar | last post by:
Hi, I'm using CDO object to send email but it doesn't send any email and it does not give an error. My code look like this: Dim iMsg2 Dim iConf2 Dim Flds2 Const cdoSendUsingPort = 2 set...
7
by: Mario Leduc | last post by:
Hi, I have a page that sends user comments with CDONTS, works fine. Until I put a URL (http://192.168.0.1). If I use http://domain.com it works fine. Why with the numeric URL, CDONTS does not...
2
by: pilar | last post by:
Hi All, I'm using a code somebody posted here. I extract the records from a query which gave me just the entries for the current date, there will be maximum 5-6 entries per days and I need to send...
11
by: hazz | last post by:
smtpClient.Send(message) is causing me problems as per specifics in the trace below. Email is sent but not without this error typically upon sending the second email, but sometimes when running...
10
by: Mike Charney | last post by:
Is there a simple way to send SMTP email from Access VBA? Mike m charney at dunlap hospital dot org
6
by: Adam Honek | last post by:
Okay. This is a little strange but here goes. I wanted to send emails and hence wrote the first sub below. It worked however it would NOT send the email UNLESS I closed the application (hence...
2
by: kennykenn | last post by:
Hi, Ive producd code to send an email after capturing info off a form,it works fine locally but when i put it live it doesnt work! the code is stopin at 'msg.send' any ideas, here the code! ...
1
by: sxwend | last post by:
I am trying to use the following post results (http://www.thescripts.com/forum/thread189759.html) and add another requirement. I need to send the results to just the email addresses that the query...
16
by: Ed Bitzer | last post by:
Trying to send groups of email with program using System.Net.Mail. I do not clear MailMessage but repeatedly loop changing only the Bcc entries. Works fine if all addresses are valid. As a simple...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 2 August 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
by: erikbower65 | last post by:
Using CodiumAI's pr-agent is simple and powerful. Follow these steps: 1. Install CodiumAI CLI: Ensure Node.js is installed, then run 'npm install -g codiumai' in the terminal. 2. Connect to...
0
linyimin
by: linyimin | last post by:
Spring Startup Analyzer generates an interactive Spring application startup report that lets you understand what contributes to the application startup time and helps to optimize it. Support for...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Sept 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
by: Taofi | last post by:
I try to insert a new record but the error message says the number of query names and destination fields are not the same This are my field names ID, Budgeted, Actual, Status and Differences ...
0
by: Rina0 | last post by:
I am looking for a Python code to find the longest common subsequence of two strings. I found this blog post that describes the length of longest common subsequence problem and provides a solution in...
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
0
by: lllomh | last post by:
How does React native implement an English player?
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.