Get Processes only getting most recently active Excel file


My goal is to get a list of all open Excel 2016 files and prompt the user to select which file they want to choose as the source of the the automation process. The issue i’m having is that only the most recently active excel file shows in the process list. I can have 3 Excel files open (eg. Book1, Book2, Book3) but only the one I select or open last (eg Book3) will show in the process list.

The general steps, I believe:

  • Get Processes --> Object collection
  • For each item in the object collection, if the application (item.ProcessName) = “Excel” then Add To Collection the window title (item.MainWindowTitle) to a List openExcel.
  • Convert the List to an array of strings (openExcel.toArray), to be used as options in an Input dialog

Any ideas why Get Processes might not be pulling everything? Apparently the above process works fine with non MS Office applications. Excel, Word, and Powerpoint do not show all instances. It’s just a guess, but we have the 32-bit version of ms office installed - would that matter?

(I would upload the file but as a new user, apparently i’m not allowed to yet)

edit with screenshots:
(apparently i can only embed 1 picture at a time too, so will reply with new screenshots)

My workflow and variables

I tested this manually, and each Excel file should have a separate instance, so this should work. I’d have to see your workflow or create something myself. I don’t have time at the moment though, but maybe I’ll check it tomorrow if noone has solved this for you by then.

Shouldn’t matter.

You can post screenshots of maybe your workflow +properties, if you want using Snipping Tool or other screencapture software.


Thank you for taking a look. The part that i’m not getting is fairly straight forward (get processes -> for each item, write process name), so hopefully someone can try it today.

Screenshot shows 3 instances of excel open but only one showing in output pane. It shows Book1 because that was the last instance i activated.

Well, one useful thing I’ve learned is that accessing certain children of the Process collection will give an Access Denied error. And the way to deal with it is to put the activity into a Try-Catch activity with Win32Exception listed in the Catch.


It’s possible this is much more complicated than i hoped: