Using Aspose.Word from COM applications

It is possible to use Aspose.Word from within COM applications such as ASP and VBScript projects. This topic outlines what you need to know in order to successfully use Aspose.Word from within a COM application.

Aspose.Word support for COM is a new feature in its early stages. Aspose.Word was not initially designed with COM clients in mind so you might experience some problems during integration. Please report the problems in the support forums and we will try to help asap.

Requirements
You need to have .NET Framework 1.0 or greater installed if you want to use Aspose.Word.

Installation
You should use the full installer Aspose.Word.msi because it registers Aspose.Word.dll for COM interoperability automatically. If you just copy a hotfix Aspose.Word.dll it will not work as COM registration is tied to the dll version.
If you still want to apply a hotfix you need to register it manually by executing this command: regasm \Aspose.Word.dll /codebase regasm.exe is a tool included in .NET Framework and must be somewhere in the C:\WINNT\Microsoft.NET folder.

ProgID
There is only one publicly creatable COM object with ProgID “Aspose.Word.Word”. It contains two “Word” because “Aspose.Word” is the library name and additional “Word” is the class name.

Late Binding Recommended
Please note that Aspose.Word does not implement COM interfaces explicitly and relies on .NET ability to generate class interfaces automatically. This allows to use .NET classes reliably from within scripting clients (ASP, VBScript) that use late binding, but it is not recommended to use from within application that use early binding to a vtable as it can create versioning problems. There is no type library provided with the component.

Usage
You can mail merge data from an ADO Recordset into a document. We have rearranged all overloaded methods so they can be called from COM.