Macros

GemBox.Document supports most of the Microsoft Word document features, but not all.

Nevertheless, unsupported features can be preserved when reading a document so that they are not lost when writing a document to the same format.

Following example demonstrates how GemBox.Document preserves macros.

Macros Screenshot
Upload your file (Drag file here)
using GemBox.Document;

class Program
{
    static void Main(string[] args)
    {
        // If using Professional version, put your serial key below.
        ComponentInfo.SetLicense("FREE-LIMITED-KEY");

        DocumentModel document = DocumentModel.Load("%InputFileName%");

        document.Save("New Macros.docm");
    }
}
Imports GemBox.Document

Module Program

    Sub Main()

        ' If using Professional version, put your serial key below.
        ComponentInfo.SetLicense("FREE-LIMITED-KEY")

        Dim document As DocumentModel = DocumentModel.Load("%InputFileName%")

        document.Save("New Macros.docm")

    End Sub

End Module

Check next example or download examples from GitHub.