Internal error 33 in module 35


My client getting below error message whle sending e-mail through Outlook

7776.error.bmp (149 KB)

Can anyone suggest me, what is the solution of this error.



I think this error is due to the automation server.Follow this link.This would help you.

I knew this error is coming, becuase I am using outlook automation & this internal error 33 will come when server response late.

But I don’t know how to resolve this issue.

You may not be using correct version of automation server.Try to use Code unit 397. Follow this link.

Hi Kathik,

Please tell me, which version of automation server can I use with NAV IN 4.0 SP3. I am not using codeunit 397 because my client want multiple pdf attachment in mail, which is possible through outlook automation.



Hi Abi,

Multiple PDF attachments is also possible if you use code unit 397. This is the better way.

Hi Kathik,

I wrote the following code but its not working properly,

Mail.NewMessage(E-Mail id 1,E-Mail id 2+’;’+E-Mail id 3, Subject, Body, Attachment1.pdf+’;’+Attachment2.pdf, FALSE); where mail is 397 codeunit var.

Can you tell what’s wrong in this.



Hi abi,

The NewMessage function in codeunit 397 accepts only 5 parameters. But you are passing parameters. The parameters are.

To email id,CC email,subject,body,attachment,dialog(boolean). Do you want to send same email to more than one person?.

For attachments, separating two files by semi colon will not serve purpose. You need to modify the attachment parameter in codeunit 397 to be an array of dimension 10. Then change the following in New message function in your code unit.

FOR i:=1 TO 10 DO
IF AttachFileName[ i ]<> ‘’ THEN BEGIN //for attach more than one file (create a array for attach file name)
BSTRConverterAttachFileName.AppendNextStringPortion(AttachFileName[ i ]);
OAttachments := OSendMail.Attachments;
OAttachment := OAttachments.Add(BSTRConverterAttachFileName);


You can call this function like this.

MESSAGE(‘message sent successfully’);

Thanks Kathik