Search The ForumSearch   RegisterRegister  LoginLogin

MailBee SMTP

 AfterLogic Forum : MailBee SMTP
Subject Topic: MakeAltBody Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
Jesper Gustavss
Newbie
Newbie


Joined: 04 December 2007
Online Status: Offline
Posts: 8
Posted: 26 November 2009 at 6:45am | IP Logged Quote Jesper Gustavss

Hi
My sendings suddenly stops while in a loop with the following error:
--
System.NullReferenceException: Object reference not set to an instance of an object.
   at MailBee.MessageClass.MakeAltBody()
--
This can happen at any time, like after 400 mails sent.
Im using the SMTP objekt and queues it to the Message Queue app.

Any ideas?
[Code]
With goSMTP.Message
     .ToAddr = ksTo
     .FromAddr = gsProfile_FromName & " <" & gsProfile_FromEmail & ">"
     .Subject = ksSubject
     .BodyFormat = 1
     .BodyEncoding = 2
     .BodyText = ksBody
     .AltBodyOptions = 2
     .Codepage = 1252
     .Charset = "ISO-8859-1"
     .CodepageMode = 1
     .Attachments.RemoveAll()
     If gsProfile_ReplyName <> "" And gsProfile_ReplyEmail <> "" Then
           .ReplyToAddr = gsProfile_ReplyName & " <" & gsProfile_ReplyEmail & ">"
     End If
     .Subject = .EncodeHeaderText("Subject", .Subject, "ISO-8859-1", 3)
     .FromAddr = .EncodeHeaderText("From", .FromAddr, "ISO-8859-1", 3)
     .MakeAltBody()

     If kSBIFOGAT_1 <> "" Then .AddAttachment(kSBIFOGAT_1)
     If kSBIFOGAT_2 <> "" Then .AddAttachment(kSBIFOGAT_2)
     If kSBIFOGAT_3 <> "" Then .AddAttachment(kSBIFOGAT_3)

     .ReturnPath = gsProfile_FromEmail
End With

goSMTP.SendToQueueEx("c:\mmq")
Back to Top View Jesper Gustavss's Profile Search for other posts by Jesper Gustavss
 
Alex
AfterLogic Support
AfterLogic Support
Avatar

Joined: 19 November 2003
Online Status: Offline
Posts: 2206
Posted: 26 November 2009 at 6:51am | IP Logged Quote Alex

Which build of MailBee.dll do you use? You can right-click MailBee.dll to find out.

Regards,
Alex
Back to Top View Alex's Profile Search for other posts by Alex
 
Jesper Gustavss
Newbie
Newbie


Joined: 04 December 2007
Online Status: Offline
Posts: 8
Posted: 26 November 2009 at 6:58am | IP Logged Quote Jesper Gustavss

Im using
5.5.0.114
Back to Top View Jesper Gustavss's Profile Search for other posts by Jesper Gustavss
 
Igor
AfterLogic Support
AfterLogic Support


Joined: 24 June 2008
Location: United States
Online Status: Offline
Posts: 6038
Posted: 26 November 2009 at 7:37am | IP Logged Quote Igor

Please upgrade your MailBee.dll installation to the latest version:

32-bit 64-bit

Detailed info regarding MailBee.dll upgrade is available here. Let us know if the update helps.

--
Regards,
Igor, AfterLogic Support
Back to Top View Igor's Profile Search for other posts by Igor
 
Jesper Gustavss
Newbie
Newbie


Joined: 04 December 2007
Online Status: Offline
Posts: 8
Posted: 26 November 2009 at 10:51pm | IP Logged Quote Jesper Gustavss

Hi again,

Im using vb.net and I removed the reference in the project and added it again. It creates this interop.mailbee.dll with version 1, but im hoping it takes the latest dll that I downloaded. Anyway the problem is still there, it suddenly breaks at MakeAltBody.
Anymore ideas?

Regards,
Jesper
Back to Top View Jesper Gustavss's Profile Search for other posts by Jesper Gustavss
 
Igor
AfterLogic Support
AfterLogic Support


Joined: 24 June 2008
Location: United States
Online Status: Offline
Posts: 6038
Posted: 27 November 2009 at 12:41am | IP Logged Quote Igor

It's hard to say what's causing this, but it looks like the issue is connected with Interop functionality and not with MailBee Objects itself.

Please make sure that you're assigning proper value to .BodyText, as assigning values like null can be a reason of the issue.

It is highly recommended to use MailBee.NET Objects in .NET applications for the following reasons:
  • reliability (naturally for native solution)
  • security (Interop usage may be disallowed in secure systems)
  • ease of deployment (no need to register ActiveX libraries)

In case if using .NET version of MailBee Objects is not an option for some reason, we recommend to upgrade your Visual Studio to the latest version (especially if you're using VS 2005) with all available service packs installed.

--
Regards,
Igor, AfterLogic Support
Back to Top View Igor's Profile Search for other posts by Igor
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump

Powered by Web Wiz Forums version 7.9
Copyright ©2001-2004 Web Wiz Guide