SYSTEM instance of Outlook opening while automation running, causing it to crash

Hi all,

We’ve been running into this error recently on a few of our automations:

The obvious issue is that there’s multiple instances of Outlook open, which we can confirm when we check the task manager.

A SYSTEM user instance of Outlook seems to be causing the issue, but we’re struggling to figure out how or why this instance is starting up. We killed the Outlook processes prior to running the automations, but what will happen is the expect VM user’s instance will open, and later in the automation the SYSTEM instance gets created.

The most puzzling thing is that this started happening in the past two weeks, despite this automation basically having functioned correctly for the better part of the last year. Has anyone else run into this or would anyone have any suggestions as to how to debug this?

Many thanks in advance

Hi @Kenvin_Lee

Which outlook activities are you using currently? can you also show the version of your mail package?

1 strategic way to get rid of this problem or any profile setup related problems would be to switch to O365 outlook activities as O365 activities doesn’t require outlook to be opened/setup on your VM’s for use. It simply works in background.

It’s an older automation, sourcing quite a large number of them from the UiPath.Mail.Actvities 1.15.2 library. Activities include:

  • Use Outlook
  • For Each Email
  • Save Attachments
  • Set Outlook Mail Categories

We’d prefer to understand what’s the crux of the issue rather than just swapping things out in interest of getting it working, but if you think it’s a versioning issue there’s no harm in us updating things.

Hi @Kenvin_Lee

This happens because Outlook is being opened in two different user contexts (VM user and SYSTEM). UiPath can’t attach when another SYSTEM instance is already running. Check that the robot isn’t running under SYSTEM, look for recent Windows/Office updates or scheduled tasks starting Outlook, and make sure Outlook is fully closed before the job starts.

Hi @Kenvin_Lee

Try opening the Task Manager and navigate to Start.
Check to see if Outlook, or any service relating to it, is present in that list.

Regards
Soren

Hi all,

Thanks for the responses.

The issue here is that the SYSTEM Outlook is opening on its own in our VM, but we can’t seem to figure out why. It doesn’t seem like it has anything to do with UiPath but it is causing the automations to fail.

We’re still trying to figure out why if anyone knows, but I’m not certain this is the right place on the forums for it now.

I would check Services (services.msc) or Scheduled jobs.

@Kenvin_Lee

Ideal way for making it furture proof would be to move away from outlook

but for short term interim solution…before opening outlook check for services related to outlook…you have get processes activity

if present dont open or kill and open

cheers