Solved

sending email to my account

Posted on 2004-04-02
51
1,202 Views
Last Modified: 2013-12-18
i set up an email me form.  the form contains a textbox and when text is typed in and a button clicked i would like for the message to get sent to my business email.  The problem is when i click the button it says the message is sent but when i check my email using lotus notes the message is not there.  could someone explain why this is happening?  if i email to my hotmail account it works.  My code is below.

 Private Sub btnemail_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnemail.Click
        oMail = New MailMessage
        oMail.From = "Bobcat_Employee"
        oMail.To = "Shaun_Barth@bobcat.com"
        oMail.Subject = "Comments and Ideas"
        oMail.Body = txtEmail.Text
        SmtpMail.SmtpServer = "127.0.0.1"  ' put here server IP address
        If txtEmail.Text.Length = 0 Then
            Me.RegisterStartupScript("Email", _
            "<script language='javascript'>alert('Enter Email text');</script>")
        Else
            SmtpMail.Send(oMail)
            Me.RegisterStartupScript("Email", _
            "<script language='javascript'>alert('Email was sent');</script>")
            txtEmail.Text = ""
        End If

    End Sub
End Class
0
Comment
Question by:tentavarious
  • 21
  • 17
  • 12
51 Comments
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
Let's check some things first:
- am I correct this is Java? or is this VBscript/VBA and COM?
- are you sending mail locally, from a server using Notes or from a server using a browser?
- did you verify the log.nsf if there are any mails sent?
- what is a MailMessage? a supertype of NotesDocument?
- is there a document.send() called anywhere?
0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
Comes down to: gimme some background info, please...
0
 

Author Comment

by:tentavarious
Comment Utility
I am using vb.net this is code behind there is some javascript that will display a message if text is sent.
I am sending locally from a server using a browser.

What i do is import a namespace from the asp.net framework " Imports System.Web.Mail" then MailMessage is a class from the imported namespace.  Then i assign a variable name like "oMail" all the properites of the class MailMessage, so i can use it with methods like oMail.from and oMail.to.  I am a vb.net programmer i am unfamiliar with lotus notes, if i change my email to my hotmail account it works.  i send the email using the STMPMail.send(oMail).  i hope this clarifies somethings.
0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
VB.net is not my cup of tea. Others will read this question, so don't worry.

Have you tried to fill in someone else's Notes mail address??

Asking the obvious probably: Is it a Notes-form? (No) Then where does Notes come in??
0
 

Author Comment

by:tentavarious
Comment Utility
I haven't tried but i will now.  Basically it is just created a web page and it uses the default like outlook express to send mail.  Maybe if i change default to lotus it will work.
0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
You got Notes MAPI installed?
0
 

Author Comment

by:tentavarious
Comment Utility
Not sure how could i tell? By the way changing the default and sending to someone else didnt work.
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
Where is the relay you are bouncing the message off ? From what i can tell you are sending an SMTP message out, that when you send it to an address that happens to be on a notes server it never arrives, but when you send it to hot mail it does.

Check to see what settings are on the SMTP inbound but one I can think of offhand is that your from address has no vaild domain, and that is one setting :

Inbound Sender Controls      
Verify sender's domain in DNS:      Enabled

Check the server log ... see what it is doing when you send the message my guess is it is bieng rejected and with no return address you have no way to know


0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
Try putting your hotmail address in the from field and send it ... see if you get a message in your hotmail account.
0
 

Author Comment

by:tentavarious
Comment Utility
I checked the mail log under c:\inetpub\mailroot\badmail and there was a whole bunch of files.
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
You have to check the log on the domino server to see if it is rejecting the mail... or like I said but a real email address in the From so you can actually get the response domino is trying to send back to you.  
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
Correction   "but a real email address"

should read "put a real email address"
0
 

Author Comment

by:tentavarious
Comment Utility
I put my hotmail address in and sent a message to my bobcat address and nothing showed up in the hotmail address.  I think my email is getting deleted somewhere along the way.
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
You have to check the domino server then ... call the admin and ask him to check the log.  tell heim the time you sent it amd your IP address  and he should be able to locate the entries in the log.  There are many settings on a domino server that will reject mail, but the log will tell you why it was rejected.  Have you looked into the bad mail files in c:\inetpub\mailroot\badmail to see if there might be a clue?
0
 

Author Comment

by:tentavarious
Comment Utility
Yes i have checked the bad mail file how to i check the domino server?
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
OK
A.  What did the bad mail files say?

B.  My guess is that you dont have direct access to your company's domino server, so you will need to do what I outlined above... contact the admin, tell him when you sent the message and your IP address and he should beable to locate the connection attempt in the domino log.  If he is not willing to do that, ask him to give you reader access to log.nsf then you can check it yourself.  You can check under mail router events and nicellaneous events (depending on the release it will vary where the relevevant info is)  then just check the times around when you sent the message, and you should be able to track down the attempt to deliver and why it wasn't received.
0
 

Author Comment

by:tentavarious
Comment Utility
ok i opened the file in notepad this is what i got not sure what to make of this.

From: postmaster@gwndhcpxx-xx
To: x@y.com
Date: Sat, 27 Mar 2004 11:29:20 -0600
MIME-Version: 1.0
Content-Type: multipart/report; report-type=delivery-status;
      boundary="9B095B5ADSN=_01C40DD5147B438000000019gwndhcpxx?xx"
Message-ID: <FRaqbC8wS0000000d@gwndhcpxx-xx>
Subject: Delivery Status Notification (Failure)

This is a MIME-formatted message.  
Portions of this message may be unreadable without a MIME-capable mail program.

--9B095B5ADSN=_01C40DD5147B438000000019gwndhcpxx?xx
Content-Type: text/plain; charset=unicode-1-1-utf-7

This is an automatically generated Delivery Status Notification.

Unable to deliver message to the following recipients, due to being unable to connect successfully to the destination mail server.

       Shaun_Barth@bobcat.com




--9B095B5ADSN=_01C40DD5147B438000000019gwndhcpxx?xx
Content-Type: message/delivery-status

Reporting-MTA: dns;gwndhcpxx-xx
Received-From-MTA: dns;gwndhcpxxxx
Arrival-Date: Thu, 25 Mar 2004 09:28:55 -0600

Final-Recipient: rfc822;Shaun_Barth@bobcat.com
Action: failed
Status: 4.4.7

--9B095B5ADSN=_01C40DD5147B438000000019gwndhcpxx?xx
Content-Type: message/rfc822

Received: from gwndhcpxxxx ([127.0.0.1]) by gwndhcpxx-xx with Microsoft SMTPSVC(6.0.2600.1106);
       Thu, 25 Mar 2004 09:28:55 -0600
thread-index: AcQSfeIX4bM8ImB+Q7eBu4MGApeQrQ==
Thread-Topic: Email from Welcome website
From: <x@y.com>
To: <Shaun_Barth@bobcat.com>
Subject: Email from Welcome website
Date: Thu, 25 Mar 2004 09:28:55 -0600
Message-ID: <000901c4127d$e2561200$420b3e0a@gwndhcpxxxx>
MIME-Version: 1.0
Content-Type: text/plain;
      charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Mailer: Microsoft CDO for Exchange 2000
Content-Class: urn:content-classes:message
Importance: normal
Priority: normal
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
Return-Path: x@y.com
X-OriginalArrivalTime: 25 Mar 2004 15:28:55.0262 (UTC) FILETIME=[E2730FE0:01C4127D]

fgdsfgsdfg


--9B095B5ADSN=_01C40DD5147B438000000019gwndhcpxx?xx--
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
Ok

What this tells you is the message was not able to be delivered to the address you intended.  But we know that already, but what it tells me is you still dont have a valid email address in the return.  

x@y.com is gonna get rejected by domino if the setting I mentioned earlier is in place.  

Instead of x@y.com replace that with your yahoo account.  Then you might *** I repeat might, get a response in your yahoo account as to why it was rejected or more likely the message might even go through.  Short of that you need to contact the admin and find out what is in the logs.

0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
Who says it ever reached the Domino server? There's nothing in the mail above hinting into that direction. I think something else must be the matter.
0
 

Author Comment

by:tentavarious
Comment Utility
Hello, i changed the oMail.from to my hotmail address and i got a postmaster couldn't complete send error.  How can i fix this?

This is an automatically generated Delivery Status Notification.

Unable to deliver message to the following recipients, due to being unable to
connect successfully to the destination mail server.

       Shaun_Barth@bobcat.com
0
 
LVL 4

Accepted Solution

by:
sreeser earned 250 total points
Comment Utility
to sjef
I didn't say anyone did.  However, it isn't likely for multiple messages to dissapear into the ether and since he can mail to hotmail, then his mail server (whatever that may be) seems able to send outbound, leaving only the inbound server to be the obstacle.  Also if it isn't reaching the domino sever then this isn't the correct forum for the question to follow that logic.  But if he checks the logs then we can see if a message was generated when he tries to send the messages.  Its called eliminating possibities.  Troubelshooting 101.
That being said.  

to tentavarious
 I sent a message to that account with no bounce back so there is no problem receiving mail if you got it.   The only other thing I can think of on you end that could be a problem is DNS problem with the mail server.  Since you have hotmail configured on your computer as a pop and smtp probably through outlook or OE then you might have a problem with resolving  bobcat.com in your DNS.  You can bypass the DNS settings by using the LMHOSTS file (find lmhosts.sam and save it as lmhosts without any suffix.  In this file, add the ip address and name of the domain to the end of the file. (you can delete all the lines that start with # if you like or you can keep them for instructions)  

xxx.xxx.xxx.xxx  bobcat.com.  

Save that file and bring up a command prompt.  In the comand prompt type

nbtstat -R  (the capital R is important)

it should say "Succsessful purge and preload" .. blah blah.

I really would like to know if there are any entries on the Domino server that correspond with these attempts. because all this is pointless if it really is reaching the server.

0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
I didn't say you said it did. The whole question remains rather vague to me. How is mail supposed to flow, and how does it actually flow? I think that has to be clear first. I just don't dare to bet that mail is NOT sent through a server to Hotmail but directly. Some clarification here would be nice.

I second your last question :)
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
:)

we are in agreement then.  Well the mail has to be bounced off a relay, and my very first question which remains to be answered was

"Where is the relay you are bouncing the message off ? "

I agree, this is shooting in the dark.  When people ask for help and ignore most of what you say, its hard to get anywhere.
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
from this line

SmtpMail.SmtpServer = "127.0.0.1"  ' put here server IP address

I was assuming the relay was his local machine, hence the DNS stuff
0
 

Author Comment

by:tentavarious
Comment Utility
Ok this is what i did i went under administrative controls, under IIS and changed the smtp default properties under the access tab and set the relay to the default ip address 127.0.0.1, should i change the ip address to something else?  I have tried your above comment i am going to now, i was just wondering if i am using the wrong ip address.
0
Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 

Author Comment

by:tentavarious
Comment Utility
See i think that is like the default ip address should i put the ip address of my machine there instead or the ip address of the server i am using to hold my web pages. i dont know which one to use?
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
I just think that you dont have the DNS set up correctly. I dont have an IIS box in front of me to tell you how to troubleshoot the DNS issue but I can check later.
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
Most likely your domino admin has restrictions in place for those who can use it as a relay, so you will have to use your web server if that  is the case... depending on the version of domino if it is R6x and your server is in the "domain" of the the domino box then you might be able to use it. There are also settigns in R6x that are more flexibel.  but you should be able to do this bouncing off your IIS box.  This really doesnt have a whole lot to do with domino i am getting the feeling.  I really think this is a DNS issue.
0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
I might be totally off, but a Notes client cannot relay mail. Dinnertime! See you later.
0
 

Author Comment

by:tentavarious
Comment Utility
sreeser i did what you said i put the 127.0.0.1 bobcat.com at the end of file and ran the nbtstat -R from the comand prompt and i tried again i got the same results.
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
Where is your notes/domino server?  that is the ip addy to put in the lmhosts file not the IIS server that you are relaying from.


0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
What does bobcat.com resolve to?
0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
Can't make head nor tails from this. Can't we start all over again??

1. IF the mail ever reaches a Domino server then there MUST be an entry in either the Mail log or the Misc log whenever something went wrong. If there is no such entry, then the server hasn't been contacted.
2. If you fill in 127.0.0.1 to get to Notes, you will never succeed, for Notes-clients cannot relay mail.
3. If you mail is indeed reported as an error, because the domain bobcat.com cannot be found, then you supplied the wrong server-IP and no DNS at all, or a faulty DNS IP-address.
4. Or is it your intention that the mail that gets sent to your hotmail account is sent to your Notes account in exactly the same way?
5. Is the local mailserver a Domino server for the domain bobcat.com?
6. Is the server's fully qualifying address correctly filled in?

Check this step by step.
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
I think #4 is what he is trying to accomplish ... but I am getting the feeling that there is no domino server anywhere and that we are wasting our time here.

Bobcat.com resolves to a division of ingersoll-rand that makes construction equipment.. is that the company you work for?  
0
 

Author Comment

by:tentavarious
Comment Utility
Yes, i am currently interning at bobcat as a computer programmer, i am not to familiar with all the back ground of emailing, my only experience is dealing with the smtp virtual server.  basically i have a comment page that uses the code i listed at the top, to email my account a comment when the button is clicked, i could only get it to work with my hotmail address.  If i can get it to work with my bobcat account, my boss has further plans for this.  I am not too sure what the dns is or the domino server.  could making changes to the smtp virtual server help and using a different ip address, i thought the problem might be in this statement  "SmtpMail.SmtpServer = "127.0.0.1"" i dont know if thats the correct ip address.
0
 
LVL 46

Assisted Solution

by:Sjef Bosman
Sjef Bosman earned 250 total points
Comment Utility
What happens if you do the following:
- open a Command.com Dos-box
- type: ping www.bobcat.com

The result at my place is dal-app20.bobcat.com [65.198.133.124], requests timing out for ping-packets are refused probably.

When sending a mail to eetestmail@bobcat.com it gets returned by mail2.irco.com, probably your central mail-server.

-type: ping mail2.irco.com results in mail2.irco.com [65.198.133.203], with timeouts.

I think it's best if you ask your local administrator to look into this problem. Further investigations from our part are pretty useless I think.

From the notepad-file above I can see that the postmaster at some weird domain returned your mail. You should be finding out where that domain is: your system, or some other system within your network (most likely, assuming that gw means gateway). Assume it is a fake message from your local system (127.0.0.1), we must conclude that your local system cannot find the mailserver for the domain bobcat.com. The above will maybe help you a little, but please do ask your local admin for assistance. The DNS settings for your system or the network must be causing this.

Did you already try someone else's system?
0
 

Author Comment

by:tentavarious
Comment Utility
Thanks both of you for the help, i will ask my administrator to resolve this problem
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
Not sure why I only get an assist when I said this several times in earlier posts.  As for the ping  it probably is simply relayed mail  also it is quite common to turn off responses to ping requests on smtp boxes so the time outs really indicate nothing. :)

Oh well c'est la vie
0
 

Author Comment

by:tentavarious
Comment Utility
I thought the ping might help me find the correct ip, so i graded before i tried really was no help and i am back to where i started, i going to have to see if system administrator could help.
0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
You can always ask EE to reassign points if you want to.

Stan: I just tried to sum up everything that came by, concluding that we cannot solve the problem from the outside. I think it's a 50-50 split of the points.
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
no disagreement there ... just wanted to know from the author why my contribution only constituted an "assist" as I had told him long ago the problem was


A) with his dns on the mail relay sending to the domino server or
B) a problem with the mail being rejected by the domino server for a variety of criteia that you can set...primarily the host not being in DNS. never been on the recieving end of a rejected mail so I am not sure that you get any response from the server.

points don't really mean much to me as us can see last time I was here in earnest was over a year ago ...just more the recognition :)  

As for the follow up... Domino server is the mail server for lotus notes.  DNS is what tells you how to resolve bobcat.com to the ip address for the mail server.  127.0.0.1 is YOUR mail relay... mail relay is the thing that takes your code creates a message and shuttles it off to the email address using DNS to locate the destinations mx record which is hte location of the mail server.  What you need in the lmhosts file is the ip address of the domino server that routes SMTP mail. At this point I am almost convinced this is the problem.
0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
Total agreement here.

Better check both files: lmhosts and hosts, the admin will know where to look.

Stan, obviously you know a lot about Notes, I still got two open problems. Would you please have a look at them? Looking forward to meet you again!
0
 

Author Comment

by:tentavarious
Comment Utility
sreeser i will have the assisted changed to accepted, i have one more question if i go under the default smtp virtual server, under the access tab and change the relay to the irco ip address which i believe is the domino server it should work, because right now i have the connection and the relay under the default smtp virtaul server set to 127.0.0.1.
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
Well it MAY work  but most likely not... here's why.  

There are open relays and closed.  open relays are easy to use and now hard to find because spammers find them and bounce literally thousands and thousands of emails off of them.  This then gets you on the ORBS black list of open relays and ppl/ISPs will not accept mail from you.  If you get your domino admin to open the relay to you you can then use it as your relay.  Depending on the version of Domino this can be easy (R6) to impossible(R4x)  If the real world IP address of your server is in the same domain as the mail server the admin may not need to do anything if he has it set as below

Perform Anti-Relay enforcement for these connecting hosts:      External hosts
Exclude these connecting hosts from anti-relay checks:      
Exceptions for authenticated users:      Allow all authenticated users to relay

This is R65 of domino.

Hope that helps
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
sjef

flattery will get you everywhere... I'll absolutely take a look.  

:)
0
 

Author Comment

by:tentavarious
Comment Utility
Thanks that clarifies things.
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
lol i guess you cant have 2 accepted answers .. still this system is better than the old one of posting a second question LOL

Did you get it worked out with your admin?
0
 

Author Comment

by:tentavarious
Comment Utility
not yet, will see if i can get it resolved tomorrow thanks for all your help i have a better understanding of what i am doing now.
0
 
LVL 4

Expert Comment

by:sreeser
Comment Utility
I am curious about the resolution ...post back when it is solved, or if you need more help

Stan
0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
Me too, I'd like to know where the "pepin" was, as they say over here.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Lack of Storage capacity is a common problem that exists in every field of life. Here we are taking the case of Lotus Notes Emails, as we all know that we are totally depend on e-communication i.e. Emails. This article is fully dedicated to resolvin…
This article covers general Notes 8.5 troubleshooting information including recreating the Notes\Data folder.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now