I have written a C# code in console application to open two excels and copy and paste data from one excel to another excel. It was working fine until the destination excel\'
I can offer another thing to look out for in addition to the solutions above, which seem to converge on this comment (on an answer by Alielson Piffer),
SUMMARY: So by the answers here we could conclude that this error may occur when Excel is showing any message in a popup window like for example "This software is not activated" or "Do you want Excel to be the default application for DOCX files?". – Elmue Jun 12 '17 at 22:43
There were no open messageboxes or prompts but there was an unended process (Word.exe in my case) in task manager that I needed to end. That fixed it.
This would explain why a restart helped another user.