Skip to main content

Helpcenter

Windows Installation

This chapter shows you how to install and setup DocxFactory on Windows.

  1. Go to www.docxfactory.com and download the Windows installation .ZIP file.

    For the Windows 32bit version download DocxFactoryWin32.zip.

    For the Windows 64bit version download DocxFactoryWin64.zip.

  2. Extract the DocxFactory\ directory into the Program Files\ directory.

    The DocxFactoryWin32.zip is extracted to the C:\Program Files (x86)\ directory.

    The DocxFactoryWin64.zip is extracted to the C:\Program Files\ directory.

Note: If there is an older version installed then delete the DocxFactory directory first (do not overwrite it). You may need to shutdown all processes using the DocxFactory.dll or the file will be locked and undeletable.

  1. Add the DocxFactory\bin\ directory to the Windows PATH used to search for executables and libraries when a program is run.

    1. Right click My Computer and click Properties.

    2. In the System Properties window, click on the Advanced tab.

    3. In the Advanced section, click the Environment Variables button.

    4. In the Environment Variables dialog box, select the PATH variable in the Systems Variable section, click the Edit button and add to the PATH the “C:\Program Files (x86)\DocxFactory\bin;” directory with a semicolon to separate it from the other directories (see picture below).

      image1.png

Note: You will need to restart all processes that use the DocxFactory.dll (or simply restart the Computer) for the changes in the PATH environment variable to take effect.

  1. To compile C++ programs using DocxFactory with Visual Studio:

  1. Add the DocxFactory/include/ directory to the list of include directories.

    In the project properties, in the C/C++ properties, in the General properties, add to the Additional Include Directories the “C:\Program Files (x86)\DocxFactory\include;” directory with a semicolon to separate it from the other directories (see picture below).

    image2.png
  2. Link to the DocxFactory.lib library.

    In the project properties, change the Configuration to “All Configurations”. Then in the Linker properties, in the General properties, add to the Additional Library Directories the “C:\Program Files (x86)\DocxFactory\lib;” directory with a semicolon to separate it from the other directories (see picture below).

    image3.png

    In the Linker properties, in the Input properties, add to the Additional Dependencies the “DocxFactory.lib;” library with a semicolon to separate it from the other libraries (see picture below).

    image4.png
  3. Add the WordProcessingCompiler.cpp and WordProcessingMerger.cpp from the DocxFactory/src/ directory to your project.

    image5.png

Note: If the project uses precompiled headers then you will need to add #include "stdafx.h" to the beginning of the code exercises. For example:

#include "stdafx.h"

#include "WordProcessingMerger.h"

.

.

.

int _tmain(int argc, _TCHAR* argv[]) {

.

.

.

}