【发布时间】:2022-01-01 12:14:46
【问题描述】:
我是开发 VSTO 插件的新手。在演练How to: Programmatically list all worksheets in a workbook 的第二个 VSTO 代码示例之后,VSTO 加载项在 Excel 2021 中没有问题,但在 Excel 2013 中的 Excel.Range rng = this.Application.get_Range("A1"); 行中抛出异常 System.Runtime.InteropServices.COMException: 'Exception from HRESULT: 0x800A03EC' 。
我在Windows11上安装了2013和2021两个版本,我使用VS2021进行开发。感谢您的回答。
【问题讨论】: