Outlook send mail problem

I followed the instructions of UiPath Academy
There are no problems with the first part of reading the email and downloading the attachment.
However, when I had to send the email with an attachment using the “send mail” activity via Outlook, the problem occurred.

After click the run button this message popup.

Something went wrong with .
Activity Send Email (Send Mail X) failed:

The operation failed. The messaging interfaces have returned an unknown error. If the problem persists, restart Outlook. The operation failed. An object cannot be found.

You can find the activity by searching id (press Ctrl + J to jump to activity):
01008

Here is the Output:

System.Runtime.InteropServices.COMException (0x8004010F): The operation failed. The messaging interfaces have returned an unknown error. If the problem persists, restart Outlook. The operation failed. An object cannot be found.
at Microsoft.Office.Interop.Outlook._MailItem.Send()
at UiPath.Mail.Outlook.Extensions.SendMailHelpers.SendMailItem(String account, Application outlookApp, MailItem mailItem)
at UiPath.Mail.Outlook.OutlookApiV2.SendMailInternal(MailMessage mailMessage, AccountWithStore account, SendMailRequest sendMailRequest, Action1 SetBody) at UiPath.Mail.Outlook.OutlookApiV2.SendMail(MailMessage mailMessage, AccountWithStore account, SendMailRequest sendMailRequest, IDictionary2 contentIdToImageFileMap)
at UiPath.Mail.Outlook.OutlookService.<>c__DisplayClass22_0.b__0()
at System.Threading.Tasks.Task.InnerInvoke()
at System.Threading.Tasks.Task.<>c.<.cctor>b__272_0(Object obj)
at System.Threading.ExecutionContext.RunFromThreadPoolDispatchLoop(Thread threadPoolThread, ExecutionContext executionContext, ContextCallback callback, Object state)
— End of stack trace from previous location —
at System.Threading.ExecutionContext.RunFromThreadPoolDispatchLoop(Thread threadPoolThread, ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading.Tasks.Task.ExecuteWithThreadLocal(Task& currentTaskSlot, Thread threadPoolThread)
— End of stack trace from previous location —
at UiPath.Mail.Activities.Business.SendMailX.ExecuteAsync(AsyncCodeActivityContext context, CancellationToken cancellationToken)
at UiPath.Shared.Activities.AsyncTaskCodeActivityImplementation.EndExecute(AsyncCodeActivityContext context, IAsyncResult result)
at UiPath.Shared.Activities.AsyncTaskCodeActivity.EndExecute(AsyncCodeActivityContext context, IAsyncResult result)
at UiPath.Mail.Activities.BaseMailAsyncActivity.EndExecute(AsyncCodeActivityContext context, IAsyncResult result)
at System.Activities.AsyncCodeActivity.System.Activities.IAsyncCodeActivity.FinishExecution(AsyncCodeActivityContext context, IAsyncResult result)
at System.Activities.AsyncCodeActivity.CompleteAsyncCodeActivityData.CompleteAsyncCodeActivityWorkItem.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)

Does anyone know what the problem is?

Thank you

Hi @ReTul2n1 ,

Welcome to the UiPath Community.

The problem appears to be an unknown error related to the messaging interfaces in Outlook. The suggestion is to restart Outlook and see if the problem persists.

Thanks,

Thank you RajKumar_DC for your reply.

Unfortunately, after restarting Outlook several times, the problem persisted.
Are there any add-ins needed to install for Outlook like Excel add-ins?

Thank you

@ReTul2n1 The error indicates issue with profile configuration or system settings (SMTP, Port) if not resolved after restart. Please try to send manually from outlook, if succeed then check the activity setting.

Attaching Link for quick reference - Send Email

Thanks

Thank you Shantanu_chande for your reply.

Here is my current SMTP/Port setting. Currently using company notebook to learn RPA.
I am currently using a POP account, not an Outlook account.
The incoming mail port is 110, while the outgoing port is 25.
image
image

Sending an email from my Outlook account to another Gmail account works flawlessly. Emails received from UiPath also showed normally.

I tried searching for the default SMTP port of UiPath Send mail activity which is 587, I think. I also cannot find any properties to set SMTP/Port for outgoing email.

After restarting Outlook the problem still persisted.
Do you know how to setup the SMTP/Port setting?
Is there a problem with my current setup?

Thank you

Hi @ReTul2n1 - Not sure but It seems to be outlook application issue.

Check this - Redirecting

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.