When you create a document-level project, the document and the associated application are hosted inside Visual Studio so you can design and work directly with the document. When you have a Microsoft Office application open in Visual Studio, it generally works as expected. However, some of the application's functionality is different or inaccessible.

Microsoft Office Word and Microsoft Office Excel offer document protection features that you can use in your Visual Studio Tools for Office projects. However, if document protection is enabled while the document is open in Visual Studio, it can prevent you from making some design changes. For more information, see Document Protection in Document-Level Solutions.

Information Rights Management (IRM) is available in Microsoft Office Word and Microsoft Office Excel. IRM can help you prevent unauthorized people from viewing or altering sensitive information. However, IRM can also prevent your code from running. For more information, see Information Rights Management and Managed Code Extensions Overview.

Microsoft Office Word documents and Microsoft Office Excel workbooks can be set so that they cannot be opened by someone who does not know the password. Password protection is handled differently in Word and Excel, and can affect your development process. For more information, see Password Protection on Office Documents.