Reputation: 394
I am trying to use win32com.client to load in a workbook and then refresh it.
I have narrowed down my problem to this error when running this command:
import win32com.client as win32
xlapp = win32.DispatchEx('Excel.Application')
pywintypes.com_error: (-2147221005, 'Invalid class string', None, None)
I have no issues when running from my local machine. However, I am running from a virtual machine that does not have excel installed. Would this be causing the error?
Upvotes: 1
Views: 758
Reputation: 199
If you do not have Excel installed, how do you expect pywin32 to dispatch it?
I think this is the main issue if you're able to make it run from your local machine.
Upvotes: 3