В настройках Excel надо разрешить программный доступ. Местоположение настройки зависит от версии Excel:
2003: Tools - Macro - Security - Trusted Publishers - Trust Access To VB Project
2007: Excel Options - Trust Center - Trust Center Settings - Macro Settings - Trust Access To VB Project