Как запретить xlwings отключать другие надстройки (SQL Spreads)Python

Программы на Python
Гость
Как запретить xlwings отключать другие надстройки (SQL Spreads)

Сообщение Гость »


У меня есть надстройка SQL Spreads для работы, не связанной с этим кодом.
Когда я пытаюсь запустить скрипт Python xlwings, он всегда аварийно завершает работу при попытке открыть книгу Excel:

Код: Выделить всё

wb_output = xw.Book(output_file_path, update_links=False)
with this error code:

Код: Выделить всё

Exception has occurred: com_error
(-2146959355, 'Server execution failed', None, None)
Изображение
When this occurs, it also disables the SQL Spreads add-in. When I run the code a second time, it functions correctly and is able to work without interruption. However, I have to re-enable my SQL Spreads extension every time after running the script.
Изображение
I have been unable to avoid the first crash and disabling of SQL Spreads. SQL Spreads requires a Microsoft account login when opened, so my suspicion is that xlwings gets timed out when SQL Spreads requests the login info.
Изображение
How can I make xlwings not disable my other add-in, and not crash the first time I run the python script?


Источник: https://stackoverflow.com/questions/781 ... ql-spreads

Вернуться в «Python»