Get mail acknowledgement

if there are several receipients........
i have read that i can use the transport options to check the acknowledgement if send to the receipient successfully....
without using dsn.jar
pls advice
MESSAGE_DELIVERED
When the message has been successfully sent to all recipients by this transport. validSent[] contains all the addresses. validUnsent[] and invalid[] are null.
MESSAGE_NOT_DELIVERED
When ValidSent[] is null, the message was not successfully sent to any recipients. validUnsent[] may have addresses that are valid. invalidSent[] may contain invalid addresses.
MESSAGE_PARTIALLY_DELIVERED
Message was successfully sent to some recipients but not to all. ValidSent[] holds addresses of recipients to whom the message was sent. validUnsent[] holds valid addresses but the message wasn't sent to them. invalid[] holds invalid addresses.
// Get a session
Session session = Session.getInstance(props, null);
// Create an empty MimeMessage and its part
Message msg = new MimeMessage(session);
... add headers and message parts as before
// create two destination addresses
Address[] addrs = {new InternetAddress("[email protected]"),
new InternetAddress("[email protected]")};
// get a transport that can handle sending message to
// InternetAddresses. This will probably map to a transport
// that supports SMTP.
Transport trans = session.getTransport(addrs[0]);
// add ourselves as ConnectionEvent and TransportEvent listeners
trans.addConnectionListener(this);
trans.addTransportListener(this);
// connect method determines what host to use from the
// session properties
trans.connect();
// send the message to the addresses we specified above
trans.sendMessage(msg, addrs);

Hi,
go thru this:
<a href="http://www.koders.com/java/fid32C7D5CB68251AD6AB16F4099820E58793770886.aspx#L78">Link</a>
regards
Shyam.
null

Similar Messages

  • TS3899 I am unable to get mail, I am getting an error message that says cannot get mail, the connection to the server failed.

    I am unable to send or receive mail.  I am getting an error message that says, cannot get mail, the connection to the server failed

    Hotmail IS having problems:
    http://bostinno.streetwise.co/2013/08/15/hotmail-outage-hotmail-is-down-for-user s-still-photos/
    http://www.engadget.com/2013/08/14/outlook-outage/
    http://www.infoworld.com/d/applications/microsofts-skydrive-outlookcom-are-down- some-users-224940
    http://mashable.com/2013/08/14/outlook-down/
    http://techcrunch.com/2013/08/14/microsoft-acknowledges-outlook-com-messenger-sk ydrive-outages/

  • Yahoo Cannot Get Mail. The connection to the server failed

    iPhone 4s with latest version of iOS.
    A few days ago my Yahoo Mail stopped connecting, and I started seeing the above noted error message (Cannot Get Mail. The connection to the server failed.)  While it won't retrieve messages, it will let me send.  So at least SMTP seems to be working OK.
    I've tried deleting it and adding it back, but to no avail.  I've rebooted the phone.  I've and any combination of options found on these boards.  Yet, the problem persists.  Anyone experience something like this before?  If so, any fix for it?

    I contacted Yahoo.  Gave them all the information.  They acknowledged that they are having an issue and that they are working to resolve it.
    One temporary measure that does work with the Mail App.  Add the Yahoo account manually. In other words, click on Other (at the bottom of the list) instead of Yahoo when adding your account, and use these settings.
    https://help.yahoo.com/kb/SLN4075.html?impressions=true

  • 2.1 - ActiveSync Cannot Get Mail still broken

    I'm still experiencing the issue where my iPhone randomly stops getting mail from Exchange/ActiveSync. The first time I experienced it after the update I deleted and recreated the exchange account, it immediately resumed working. The second time I did a complete restore as a new phone, and the issue reappeared again a few hours later.
    Here's what I do know:
    -This issue is NOT with the exchange server as we have numerous other Windows Mobile devices using activesync with no service interruption whatsoever. The iPhone however will not receive mail on the Exchange account until I delete/reconfigure the account on the iPhone itself.
    -Rebooting the iPhone used to work, however does not work anymore.
    -I have even kept WiFi disabled so it's not related to switching between WiFi and 3G.
    -I have 2 other accounts configured, a mobileme account set to sync contact and bookmarks only, and a gmail account.
    Has Apple even officially acknowledged this issue?

    I have all sorts of problem on my iphone too and the 2.1 update seems to have made its worse. We are running Exchange 2003 and I have been using Windows Mobile Activesync flawlessly for about 2 years. I dont want to Push email because I understand its guzzles battery life, so I am setting my phone to Manual collection. The iPhone only seems to download e-mail once I its been read using Outlook, (either OWA or Outlook client) I have tried just about everthing on the iphone to get it to work, so far all to no avail. Bottom line, at the moment it aint working reliably which is terribly disappointing because e-mail is the most important thing for me. The only saving grace is that OWA works pretty well in Safari, however with the flaky connection with 3G or GPRS, unfortunately this isnt robust enough to depend on! I think I may see if I can switch to IMAP as I understand others are doing!

  • Cannot get maile connection to server failed

    followed the instructions for icloud set up in apple support for ipad and iphone even deleted the account and then set the account up with the correct ID and password.  I do use a different ID  than my apple ID for my icloud account.  I use my me.com email address.  I can get into the cloud on my pc and I can send and recieve email when I log into my icloud account but this fails to work on my ipad and iphone.  Attempts to seen or get email on these devices when on a wifi network end up with the message "cannot get mail connection to server failed"
    lee

    Hi HLSdoc,
    Thanks for using Apple Support Communities.
    For more information on this, take a look at this article:
    iCloud: Troubleshooting iCloud Mail
    http://support.apple.com/kb/ts4002
    Issues sending or receiving mail on iPhone, iPad, or iPod touch
    Best of luck,
    Mario

  • Cannot Get Mail Connection to Server Failed

    Ok, I am not a very good with setting things up but I have the itouch 16GB, I have managed to set up my email and am receiving new ones but I can not connect when I am away from my home, everytime I try to connect I get the following message, *Cannot get mail,The connection to the server "pop3.live.com" failed.* Can anyone help as to what I have done wrong or what I need to do to make this work. Many thanks

    Tina,
    You need a good WiFi connection first. You can get a WiFi signal, tell your touch to connect to the network (which it does) and still not be able to do anything - like check e-mail.
    I've noticed that a lot of free hotspots here in the States make you go through a web page to "log on" to their networks. Even if it is free, you still have to go through this system.
    Next time this happens, open Safari and touch one of your bookmarked pages. Chances are the network log on screen will pop up. Do whatever it asks, and that network will release your log on to begin working.

  • How do I get mail to work through windows 7

    I understand that outlook express will not work with windows 7 so how do I get mail and music on icloud

    dougdab wrote:
    I understand that outlook express will not work with windows 7 so how do I get mail and music on icloud
    You need Outlook. 2007 or 2010.

  • How do I get mail to keep font size?

    My signature files were set to use a Helvetica 12 point font, and I have also tried an Arial 12 point font, but when I email to users who all use outlook (at different sites, and not all on exchange) the email shows up with a much bigger font.
    Any suggestions on how to get mail to send the right font?  my signature looks quite funny in 18 point font. :-)

    My signature files were set to use a Helvetica 12 point font, and I have also tried an Arial 12 point font, but when I email to users who all use outlook (at different sites, and not all on exchange) the email shows up with a much bigger font.
    Any suggestions on how to get mail to send the right font?  my signature looks quite funny in 18 point font. :-)

  • Iphone mail app regularly requires restart to get mail flowing???

    Anyone seeing this issue?  Advice re how to fix? 
    My iphone mail app regularly requires restart to get mail flowing.  That is it is running (doesn't crash) but will at time just stop getting email updates.  I then have to force close the mail app (i.e. kill it) and then restart it.  After restarting it the mail flows again.
    Notes:
    a) I do connect to Gmail for my mail - I'm using the IMAP facility for gmail currently (i.e. not the "Exchange" method)
    b) I do also have the Google "Gmail" app running on my device too
    c) on iPhone 3GS, latest version of IOS

    I have this same problem too.  I have both a hotmail and work Microsoft Exchange account setup on my iPhone and have intermitent issues with both.  Sometimes the hotmail push works, but my work email doesn't push, other times it's backwards, and sometimes neither work.  I can't figure it out.  Usually restarting the app (closing out of the multitasking bar), and/or going into settings and disabling the affected mail account works.  And to top it, I have an iPad, I'll hear the mail chime go off on my iPad, expecting it to go off on my phone....and it never does, not until I manually fetch it.
    Very frustrating.

  • I created a second email account with a password but when I try to get mail for it and I put in password it says login failed. Why? and how do I fix it.

    I created second email account ([email protected]) with a Password but when I try to get mail and enter password, it says "Sending of Password did not succeed. Mail server mail.comcast.net responded: login failed". What am I doing wrong?

    Have you logged on to the webmail account using a browser and enabled either Pop or Imap forwarding for that email address?
    Have you created a mail account in Thunderbird that uses the chosen webmail forwarding option?
    Password - make sure caps lock is not switched - it must be the same password you use to access the webmail account.
    check:
    Tools > account Settings > Server Settings
    username = full email address
    Please post info:
    In Thunderbird
    Help > Troubleshooting information
    click on 'copy text to clipboard'
    paste info in this question
    edit /remove all info on fonts and printers.

  • Long Delay Getting Mail OSX 10.9.2

    After Upgrading to Mavericks, I am getting 15 or 20 second delay after clicking on Get Mail before email (POP) is downloaded. All other functionality on system seems normal. I have only one email account.
    Here is EtreCheck info for what it's worth:
    Hardware Information:
              MacBook Pro (13-inch, Mid 2009)
              MacBook Pro - model: MacBookPro5,5
              1 2.26 GHz Intel Core 2 Duo CPU: 2 cores
              8 GB RAM
    Video Information:
              NVIDIA GeForce 9400M - VRAM: 256 MB
    System Software:
              OS X 10.9.2 (13C64) - Uptime: 1 day 13:27:9
    Disk Information:
              WDC WD3200BPVT-00HXZT3 disk0 : (320.07 GB)
                        EFI (disk0s1) <not mounted>: 209.7 MB
                        MacintoshHD (disk0s2) / [Startup]: 319.21 GB (104 GB free)
                        Recovery HD (disk0s3) <not mounted>: 650 MB
              HL-DT-ST DVDRW  GS23N 
    USB Information:
              Apple Inc. Built-in iSight
              Apple Internal Memory Card Reader
              Apple Inc. Apple Internal Keyboard / Trackpad
              Apple Computer, Inc. IR Receiver
              Logitech USB Receiver
              EPSON USB Printer
              Apple Inc. BRCM2046 Hub
                        Apple Inc. Bluetooth USB Host Controller
    FireWire Information:
    Thunderbolt Information:
    Kernel Extensions:
              com.intego.netbarrier.kext.monitor          (653)
              com.intego.netbarrier.kext.network          (653)
              com.intego.netbarrier.kext.process          (653)
    Startup Items:
              VirtualPCOSServices: Path: /Library/StartupItems/VirtualPCOSServices
    Launch Daemons:
              [System] com.adobe.fpsaud.plist 3rd-Party support link
              [System] com.bombich.ccc.plist 3rd-Party support link
              [System] com.intego.commonservices.daemon.integod.plist 3rd-Party support link
              [System] com.intego.commonservices.daemon.taskmanager.plist 3rd-Party support link
              [System] com.intego.commonservices.icalserver.plist 3rd-Party support link
              [System] com.intego.commonservices.metrics.kschecker.plist 3rd-Party support link
              [System] com.intego.netbarrier.daemon.logger.plist 3rd-Party support link
              [System] com.intego.netbarrier.daemon.monitor.plist 3rd-Party support link
              [System] com.intego.netbarrier.daemon.plist 3rd-Party support link
              [System] com.intego.netupdate.daemon.plist 3rd-Party support link
              [System] com.intego.virusbarrier.daemon.emlparser.plist 3rd-Party support link
              [System] com.intego.virusbarrier.daemon.logger.plist 3rd-Party support link
              [System] com.intego.virusbarrier.daemon.plist 3rd-Party support link
              [System] com.intego.virusbarrier.daemon.scanner.plist 3rd-Party support link
              [System] com.vmware.launchd.vmware.plist 3rd-Party support link
              [System] org.macosforge.xquartz.privileged_startx.plist 3rd-Party support link
    Launch Agents:
              [System] com.intego.commonservices.integomenu.plist 3rd-Party support link
              [System] com.intego.commonservices.taskmanager.plist 3rd-Party support link
              [System] com.intego.commonservices.uninstaller.plist 3rd-Party support link
              [System] com.intego.netbarrier.alert.plist 3rd-Party support link
              [System] com.intego.netupdate.agent.plist 3rd-Party support link
              [System] com.intego.virusbarrier.alert.plist 3rd-Party support link
              [System] org.macosforge.xquartz.startx.plist 3rd-Party support link
    User Launch Agents:
              [not loaded] com.google.keystone.agent.plist 3rd-Party support link
    User Login Items:
              System Events
              ConnectService
    Internet Plug-ins:
              Flip4Mac WMV Plugin: Version: 2.3.0.14 3rd-Party support link
              FlashPlayer-10.6: Version: 12.0.0.77 - SDK 10.6 3rd-Party support link
              Default Browser: Version: 537 - SDK 10.9
              Flash Player: Version: 12.0.0.77 - SDK 10.6 3rd-Party support link
              OVSHelper: Version: 1.0 3rd-Party support link
              DivXBrowserPlugin: Version: 2.1 3rd-Party support link
              QuickTime Plugin: Version: 7.7.3
              Silverlight: Version: 5.1.30214.0 - SDK 10.6 3rd-Party support link
              MacCouponPrinter3: Version: (null)
              iPhotoPhotocast: Version: 7.0
    Safari Extensions:
              ClickToFlash: Version: 2.9.2
              DivX Plus Web Player HTML5 <video>: Version: 2.1.1.94
              Open in Internet Explorer: Version: 1.0
              DivX HiQ: Version: 2.1.1.94
    Audio Plug-ins:
              BluetoothAudioPlugIn: Version: 1.0 - SDK 10.9
              AirPlay: Version: 2.0 - SDK 10.9
              AppleAVBAudio: Version: 203.2 - SDK 10.9
              iSightAudio: Version: 7.7.3 - SDK 10.9
    iTunes Plug-ins:
              Quartz Composer Visualizer: Version: 1.4 - SDK 10.9
    User Internet Plug-ins:
              Move-Media-Player: Version: npmnqmp 071705000010 3rd-Party support link
              FolxNetscapePlugIn: Version: 1.0 3rd-Party support link
              Picasa: Version: 1.0 3rd-Party support link
    3rd Party Preference Panes:
              DivX  3rd-Party support link
              Flash Player  3rd-Party support link
              Flip4Mac WMV  3rd-Party support link
              MacFUSE  3rd-Party support link
    Old Applications:
              /Users/[redacted]/Downloads
                        Logitech Control Center Installer:          Version: 1.0.5 - SDK 10.0 3rd-Party support link
                        LCC Installer 2:          Version: 1.0.5 - SDK 10.0 3rd-Party support link
              Epson Printer Utility 4:          Version: 9.19 - SDK 10.5 3rd-Party support link
                        /Library/Printers/EPSON/InkjetPrinter2/Utility/UT4/Epson Printer Utility 4.app
              SLLauncher:          Version: 1.0 - SDK 10.5 3rd-Party support link
                        /Library/Application Support/Microsoft/Silverlight/OutOfBrowser/SLLauncher.app
              iSkysoft DVD Ripper:          Version: 2.5.3 - SDK 10.5 3rd-Party support link
                        /Applications/Not Usable/iSkysoft DVD Ripper.app
              CollageIt for Mac:          Version: 1.0 - SDK 10.0 3rd-Party support link
    Time Machine:
              Time Machine not configured!
    Top Processes by CPU:
                   9%          WindowServer
                   2%          EtreCheck
                   1%          ConnectService
                   0%          PluginProcess
                   0%          Safari
    Top Processes by Memory:
              795 MB          firefox
              205 MB          PluginProcess
              172 MB          com.apple.IconServicesAgent
              156 MB          softwareupdated
              139 MB          WindowServer
    Virtual Memory Information:
              44 MB          Free RAM
              3.44 GB          Active RAM
              3.43 GB          Inactive RAM
              858 MB          Wired RAM
              2.04 GB          Page-ins
              0 B          Page-outs

    Please read this whole message before doing anything.
    This procedure is a diagnostic test. It’s unlikely to solve your problem. Don’t be disappointed when you find that nothing has changed after you complete it.
    The purpose of the test is to determine whether the problem is caused by third-party software that loads automatically at startup or login, by a peripheral device, by a font conflict, or by corruption of the file system or of certain system caches.
    Disconnect all wired peripherals except those needed for the test, and remove all aftermarket expansion cards, if applicable. Start up in safe mode and log in to the account with the problem. You must hold down the shift key twice: once when you boot, and again when you log in.
    Note: If FileVault is enabled, or if a firmware password is set, or if the boot volume is a Fusion Drive or a software RAID, you can’t do this. Ask for further instructions.
    Safe mode is much slower to boot and run than normal, with limited graphics performance, and some things won’t work at all, including sound output and Wi-Fi on certain models. The next normal boot may also be somewhat slow.
    The login screen appears even if you usually login automatically. You must know your login password in order to log in. If you’ve forgotten the password, you will need to reset it before you begin.
    Test while in safe mode. Same problem?
    After testing, reboot as usual (not in safe mode) and verify that you still have the problem. Post the results of the test.

  • New iMac, migrated from macbook and now mail won't work. Tried re-installing operating system, still doesn't work. Can anyone help me to get mail working? thanks

    I just bought a new iMac and I thought that it would be simple to migrate from my MacBook.
    I have a time machine back-up so I decided to migrate using that. Everything seemed to instal pretty well with the exception of mail.  To begin with I had 2 mail icons, then I started to read some forums and checked that i had the one I wanted in the applications folder, deleted the other and then downloaded the new operating system.  Mail had to be force quit first and even when the download was complete Mail still wouldn't open or run. The only thing I can do is compose a new message, but I can't see my inbox at all.
    It's really frustrating and I would love to know in a simple step by step guide how to get mail up and running with my existing migrated emails in it.
    If anyone can give me some advice that would be great.
    thanks in advance.
    H

    Problems such as yours are sometimes caused by files that should belong to you but are locked or have wrong permissions. This procedure will check for such files. It makes no changes and therefore will not, in itself, solve your problem.
    First, empty the Trash.
    Triple-click the line below to select it, then copy the selected text to the Clipboard (command-C):
    find ~ $TMPDIR.. \( -flags +sappnd,schg,uappnd,uchg -o ! -user $UID -o ! -perm -600 -o -acl \) 2> /dev/null | wc -l
    Launch the Terminal application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad. Click Utilities, then Terminal in the icon grid.
    Paste into the Terminal window (command-V). The command may take a noticeable amount of time to run. Wait for a new line ending in a dollar sign (“$”) to appear.
    The output of this command, on a line directly below what you entered, will be a number such as "41." Please post it in a reply.

  • How do I stop the message "user name or password for iCloud is incorrect" from popping up 2 times in a row when i try to get mail from other accounts? thank you in advance

    How do I stop the message "Cannot get mail. The user name or password for iCloud is incorrect" from popping up 2-4 times consecutively every time I choose MAIL on my iPhone 4,  7.1.1  I have to select "OK" 2-4 times each time before I can read other email accounts.  I used to have an "@me.com" account which I think was automatically changed to an "@icloud.com account."  I opened a new iCloud.com account yesterday because I could not figure out how to get in the old ones.  I want to delete the original @me & original iCloud account.  When I try to delete the account, they tell me my DOB is wrong. I just want those pop ups to stop.  Thanks in advance for your help.

    Hi Suzanne,
    It sounds like you’re running into a password issue with an older Apple ID that’s setup on your iPhone, which is preventing you from removing an iCloud account from your device. Take a look at the article linked below, it outlines all of the possible ways to change an Apple ID password.
    If you forgot your Apple ID password - Apple Support
    After you enter your Apple ID, there are three ways you can change your password:
    Answer your security questions. Use these steps if you know the answers to your security questions.
    Use email authentication. We'll send you an email that you can use to change your password.
    Use two-step verification. If you set up two-step verification, you can use it to change your password. You just need your recovery key and a trusted device.
    So long,
    -Jason

  • How do set up your hotmail account on a mac book pro? I have it set up so I get mail but on my hotmail account I have lot of separate folders. They don't show up on my mac, they do on my iPhone and iPad.

    How do set up your hotmail account on a mac book pro properly? I have it set up so I get mail but on my hotmail account I have lot of separate folders to save messages in(for example :- bank, skyp, work, Facebook, apple, ect...). They don't show up on my mac. I also have an iPhone and iPad, there is no issue here when I set those up. I automatically got my separate folders. Anybody have any idea or encountered the same problem?

    Leuvy13 wrote:
    Cheers,
    I'm not gonna lie, I actually have no idea if its pop or imap. Do you know where you can check and if it can be changed?
    Hotmail on a Mac is POP3 only, you will only get the basic folders (inbox, sent, trash etc) and it will not sync with other devices.
    And now I post this I see other replies, so this is redundant. !!

  • How do I get mail on my iPhone and computer to sync automatically, so e.g. messages read on one appear read on both?  I am working in VN and the microsoft access server is in the USA.

    How do I get mail on my iPhone and computer to sync automatically, so e.g. messages read on one appear read on both?  I am working in VN and the microsoft access server is in the USA.

    If you created as an Exchange account on the iPhone (not IMAP or POP) and you have Push on it should all work smoothly; Reading a message on either client should mark the other read (it does on mine). Try deleting the account from the phone, rebooting the phone (to clear out old settings), then go to Settings/Mail,Contacts,Calendar, add an account and tap Microsoft Exchange and add the account back.
    There is a fundamental difference between BB and iPhone that you should be aware of; on the BB you do not sync directly with Exchange; you sync with the RIM server which then syncs with your Exchange server. The iPhone syncs directly with Exchange using Microsoft's ActiveSync protocol. So in some ways they will behave differently. But ActiveSync should manage marking messages as read correctly.

Maybe you are looking for