[RESOLVED] Sending emails in Win7 gives me error 48389-VBForums
Results 1 to 8 of 8

Thread: [RESOLVED] Sending emails in Win7 gives me error 48389

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Jan 2009
    Posts
    17

    Resolved [RESOLVED] Sending emails in Win7 gives me error 48389

    Hi,

    in my vb6 application I'm using mapi for sending email to from my client to other recipients.
    Now my client has on his computer Windows 7 and sending email doesn't work anymore. He has also Outlook 2007.
    On his computer this line:
    MAPIMessages1.ResolveName
    gives me the error 48389. But no description, what it means.

    Sending email works ok on my computer, where I have Windows XP and Outlook 2007.

    So, how can I resolve this problem?

    Thanks in advance.
    Last edited by Spajder; Mar 1st, 2010 at 06:50 AM.

  2. #2
    PowerPoster Nightwalker83's Avatar
    Join Date
    Dec 2001
    Location
    Adelaide, Australia
    Posts
    13,120

    Re: Sending messages in Win7 gives me error 48389

    Does this help?
    when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
    If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
    Please consider giving me some rep points if I help you a lot.
    Links to my code examples can now be found on my website: My websites
    Please rate my post if you find it helpful!
    Technology is a dangerous thing in the hands of an idiot! I am that idiot.

  3. #3

    Thread Starter
    Junior Member
    Join Date
    Jan 2009
    Posts
    17

    Re: Sending messages in Win7 gives me error 48389

    No, it didn't help me much, because my project works on the same way as yours. In line MAPIMessages1.ResolveName i still get the error 48389.

    Maybe I should rephrase myself:
    How to program my vb6 project, so it would work with any deafult email client everywhere (no matter what Windows and email clients users have)?

    Can someone help me please?

  4. #4
    Freelancer akhileshbc's Avatar
    Join Date
    Jun 2008
    Location
    Trivandrum, Kerala, India
    Posts
    7,573

    Re: Sending messages in Win7 gives me error 48389

    Quote Originally Posted by Spajder View Post
    No, it didn't help me much, because my project works on the same way as yours. In line MAPIMessages1.ResolveName i still get the error 48389.

    Maybe I should rephrase myself:
    How to program my vb6 project, so it would work with any deafult email client everywhere (no matter what Windows and email clients users have)?

    Can someone help me please?
    If you don't want to use the programs like Outlook,etc... then, you can try using the vbsendmail or CDO for sending mails....

    Links:
    Using CDO for sending mails:
    * http://www.vbforums.com/showthread.p...=sending+email
    * http://www.vbforums.com/showthread.p....message+gmail

    Using vbsendmail:

    * http://www.vbforums.com/showthread.p...ght=vbsendmail

    For more, search the forum....

    If my post was helpful to you, then express your gratitude using Rate this Post.
    And if your problem is SOLVED, then please Mark the Thread as RESOLVED (see it in action - video)
    My system: AMD FX 6100, Gigabyte Motherboard, 8 GB Crossair Vengance, Cooler Master 450W Thunder PSU, 1.4 TB HDD, 18.5" TFT(Wide), Antec V1 Cabinet

    Social Group: VBForums - Developers from India

    Skills: PHP, MySQL, jQuery, VB.Net, VB6, Photoshop...

  5. #5

    Thread Starter
    Junior Member
    Join Date
    Jan 2009
    Posts
    17

    Re: Sending messages in Win7 gives me error 48389

    Is there a chance, that I could keep my MAPI for sending emails with attachments in Windows 7?

    This MAPIMessages1.ResolveName problem really bugs me

  6. #6

    Thread Starter
    Junior Member
    Join Date
    Jan 2009
    Posts
    17

    Sending emails in Win7 gives me error 48389 - Solution with new problem

    I've got it!

    somehow, if I'm sending email with mapi from Outlook to someones email address, his email address loses his E-mail type. If I click into Sent items, search my email, sent from my vb6 application, and make a right click on recipients email address and choose Outlook Properties, I would see his E-mail type like the one in the left picture. And this was wrong!

    Here is the example from my solution:
    Code:
    If MAPISession1.SessionID <> 0 Then
       MAPISession1.SignOff
    End If
    MAPISession1.SignOn
    MAPIMessages1.SessionID = MAPISession1.SessionID
    MAPIMessages1.Compose
    
    MAPIMessages1.RecipAddress = "smtp: MyEmail@test.com"
    MAPIMessages1.RecipDisplayName = "smtp: MyEmail@test.com"
    MAPIMessages1.AddressResolveUI = True
    
    MAPIMessages1.MsgSubject = "My email with attachment"
    MAPIMessages1.AttachmentPathName = Path & "\" & name
    MAPIMessages1.MsgNoteText = "Hi there. " & Chr(10) _
         & "Here are some pgp files for you!"
    MAPIMessages1.send False 
    If MAPISession1.SessionID <> 0 Then
       MAPISession1.SignOff
    Else
       MsgBox "This email could not be send to recipient!"
    End If
    I have removed the line with MAPIMessages1.ResolveName and have added "smtp:" to MAPIMessages1.RecipAddress and have done the same with MAPIMessages1.RecipDisplayName. I have also added MAPIMessages1.AddressResolveUI = True

    With this code I can send email with attachment without any error!
    If I would now check Outlook properties, the email type would be now correct (see the right picture).

    So this problem is solved. But now I have another problem (please see the new thread, because this thread is resolved).
    Some of recipients emailed back to me, telling me, that email attachments (like file.pgp) are in wrong format or the files are not attached at all. Some of them have had attached this file: Winmail.Dat.

    How could this be? Have I missed something??? I suspect Outlook for this weird behavior.
    Can someone help me please?

    Thank you
    Attached Images Attached Images   
    Last edited by Spajder; Apr 2nd, 2010 at 01:26 AM.

  7. #7
    New Member
    Join Date
    Jun 2010
    Posts
    2

    Re: [RESOLVED] Sending emails in Win7 gives me error 48389

    I have been facing the same issue on one of our legacy application - MAPIMessages1.Show (to display users list) gives me the error 48389. This error could happen everywhere as long as you use MAPI on windows 7.. at the time i'm writing this, there is not yet a service pack to fix the issue, but fortunately
    There is a link to hotfix this issue http://support.microsoft.com/kb/980681

    i have tested it and it works perfect - good luck


    For references --------------------------------
    For all supported x86-based versions of Windows 7
    Collapse this tableExpand this tableFile name File version File size Date Time Platform
    Fixmapi.exe 6.1.7600.16385 14,336 14-Jul-2009 01:14 x86
    Mapi32.dll 6.1.7600.20652 76,800 24-Feb-2010 07:30 x86
    Mapistub.dll 6.1.7600.20652 76,800 24-Feb-2010 07:30 x86

    For all supported x64-based versions of Windows 7 and of Windows Server 2008 R2
    Collapse this tableExpand this tableFile name File version File size Date Time Platform
    Fixmapi.exe 6.1.7600.16385 17,408 14-Jul-2009 01:39 x64
    Mapi32.dll 6.1.7600.20652 91,648 24-Feb-2010 08:05 x64
    Mapistub.dll 6.1.7600.20652 91,648 24-Feb-2010 08:05 x64

    For all supported IA-64-based versions of Windows Server 2008 R2
    Collapse this tableExpand this tableFile name File version File size Date Time Platform
    Fixmapi.exe 6.1.7600.16385 36,352 14-Jul-2009 01:44 IA-64
    Mapi32.dll 6.1.7600.20652 186,368 24-Feb-2010 06:36 IA-64
    Mapistub.dll 6.1.7600.20652 186,368 24-Feb-2010 06:36 IA-64

  8. #8
    New Member
    Join Date
    Jun 2010
    Posts
    2

    Re: [RESOLVED] Sending emails in Win7 gives me error 48389

    Again, i believe you don't have to mess with your working code.

    Good luck

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Featured


Click Here to Expand Forum to Full Width

Survey posted by VBForums.