Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

COMException (0x800A03EC) on workbook.VBProject.VBComponents

48 views
Skip to first unread message

FaithRaven

unread,
Feb 12, 2010, 9:28:01 AM2/12/10
to
Hello

I am getting:

System.Runtime.InteropServices.COMException (0x800A03EC): Exception from
HRESULT: 0x800A03EC at
Microsoft.Office.Interop.Excel.WorkbookClass.get_VBProject()

On the office 2007 addin I've built.

The gotha is that the client has already enabled the Trust Access to VBA in
Excel 2007 and also this is happening only to a select number of clients, not
all of them.

Any other ideas why this might occur ? Below is the full code snippet:
VBComponent result = null;

if (workbook.VBProject.VBComponents.Count > 0)
{
foreach (VBComponent macroModule in
workbook.VBProject.VBComponents)
{
if (macroModule.Name == sheet.Name)
{
result = macroModule;
break;
}
}
}

Thanks

0 new messages