New in .NET 2.0 for Windows Forms applications is a deployment feature known as “Registration-Free COM.” This allows you to use and deploy certain COM components such as ActiveX controls to client computers without registering the component on the local machine with your installer or manually using regsvr32.exe, with some limitations.
The DsoFramer control allows you to embed and control applications such as Microsoft Office programs directly inside your Windows Forms application. For example, your users might need to interact with or preview an Excel spreadsheet containing sales data, or perhaps preview a generated form letter created by Word. Until Microsoft releases a more fully supported .NET control (ActiveDocumentHost, anyone?), the DsoFramer is your best bet today for hosting unmanaged Office applications inside your Windows Forms client.
To enable Registration-Free COM for the DsoFramer control within your Visual Studio .NET 2005 project, simply right-click your unmanaged project reference, select Properties, and then on the properties panel for the reference, set “Isolated” to “True”. This will tell Visual Studio to generate a COM registration manifest for your application with the information necessary to activate and launch your unmanaged control.
By using this deployment feature new to .NET 2.0, you can in certain cases, enable your application to support XCOPY or ClickOnce deployment, where you otherwise would have to rely on a traditional setup project or manual registration for deployment.
- MS KB 311765 – DsoFramer Control
- GotDotNet: DsoFramer Enhancements – addresses some event related bugs in the original MS sample
- MSDN: Registration-Free COM Interop (be sure to read the part on limitations)
- MSDN: Escape DLL Hell: Simply App Deployment with ClickOnce and Registration-Free COM
- MSDN: Requirements for Registration-Free COM Interop
[tags: dsoframer, registration free com, regfreecom, smart clients, clickonce, xcopy]