Well, up until the last paragraph, my answer was going to be “Kill all Excel.exe” after each website loop.
This would terminate any Excel running on the computer, same as if you manually went to Task Manager and right click -> end task on each Excel process you found.
The concern would be unaccounted Excel running and accidentally closing one of those. So, here is the best workaround I can think of:
On the other flows that aren’t part of this one, start the flow with an environment variable %DoNotCloseExcel% and set it to TRUE. When the flow is complete, set the variable to FALSE.
Now, in this one, after each website, when you want all prior excel closed, you could say:
Loop
Get Environment Variable %DoNotCloseExcel%
If %DoNotCloseExcel% = FALSE
Kill Excel.exe
Exit Loop
Else
Wait 1 min
EndIF
End
This will stop in the loop until Excel can be closed and kill all excel.exe before moving onto the next website.
Best of luck!