Hi,
Which version of Microsoft Visual Studio Tools do you use?
Do you confirm the following things:
Conclusion
An add-in or customization for Visual Studio Tools for the Office system needs permission to run. If you build Microsoft Office 2003 solutions with any version of Visual Studio Tools for the Office system or if you build 2007 Office system solutions by using
Microsoft Visual Studio 2005 Tools for the 2007 Microsoft Office system (Second Edition), you have to grant full trust permission to the assembly.
By default, these solutions do not have permission to execute. This is a source of confusion and difficulty for developers working with Visual Studio Tools for the Office system. There are documented ways to make this easier. However, they require extra
steps and not everyone is fully aware of them.
As you see in this article, Visual Studio 2008 Professional enables you to use ClickOnce to deploy solutions for the 2007 Office system. ClickOnce, by default, gives Microsoft Office solutions full trust permissions. The extra step that has caused issues
in the past is now built-in. This is a welcome enhancement to the product.
ClickOnce is easy to use, but it also provides several layers of control. You can determine which of the techniques you have seen here to use for your solutions and customers.
http://msdn.microsoft.com/en-us/library/bb821233(v=office.12).aspx
Best regards,
Rex Zhang
TechNet Community Support
