Мой проект C# использует Office.interop.excel для создания и сохранения файлов Excel. Он работал нормально с Office 2013, но я только что установил Office 2024, и теперь есть большая проблема - проект строится нормально, но при запуске исключение добавляется на показанной линии -
xecection ogplect ablecting ablement ablecting ablecting ablement. Я понятия не имею, как исправить. Я ценю любую помощь. < /P>
Обновление - спасибо за комментарии.
не работает на сервере,
. Net Framework 4.7.2,
Скомпилирован для x64
не обновил ссылку на Com на новую версию Office - как мне это сделать? />hkey_classes_root\ excel.application \clsid
(по умолчанию) reg_sz {00024500-0000-0000-c000-0000000046}
Я выхожу из города-не смогу работать над этим в течение нескольких дней. < /P>
Update July 3 - I have updated the reference to Microsoft Excel 16.0 Object Library Version 1.9
My version of Office is: Microsoft Office LTSC Standard 2024 -en -us
In Power Shell I ran the following -
PS C:\Users\Victor> reg query HKCR\Excel.Application\CLSID
HKEY_CLASSES_ROOT\Excel.Application\CLSID
(Default) REG_SZ {00024500-0000-0000-C000-000000000046}
PS C:\Users\Victor> reg export HKLM\Software\Classes\CLSID\00024500-0000-0000-C000-000000000046 C:\Users\Victor\Documents\HKLM_CLSID.txt
ERROR: The system was unable to find the specified registry key or value.
and also -
PS C:\Users\Victor> reg export HKLM\Software\WOW6432Node\Classes\CLSID\00024500-0000-0000-C000-000000000046 C:\Users\Victor\Documents\HKLM_WOW6432Node_CLSID.txt
ERROR: The system was unable to find the specified registry key or value.
The GUID reported in the first step cannot be found when doing the export for some reason.
Note the GUID shown in Solution Explorer is different - {00020813-0000-0000-C000-000000000046} but this GUID produces the same error when doing the export.
Подробнее здесь: https://stackoverflow.com/questions/796 ... ffice-2024
Interop.excel не работает с Office 2024 ⇐ C#
-
- Похожие темы
- Ответы
- Просмотры
- Последнее сообщение
-
-
Office.Interop.Excel и Office.Interop.Outlook Развертывание по щелчку мыши и Windows 11
Anonymous » » в форуме C# - 0 Ответы
- 41 Просмотры
-
Последнее сообщение Anonymous
-