Skip to main content

How to Build Zonal OCR

  1. Clone the repository from the ZonalOCR project in DevOps.
    a. Right after the clone finishes, you may need to get the appropriate .NET Framework version. Simply download the version it asks for - you do not need to uninstall any other versions you may have.
  • NOTE: You can no longer download the developer pack for .NET Framework 4.0 and 4.5. We have a workaround for this though. Use this link and follow the instructions in the comment on the drawer. For .NET Framework 3.5 click here for the installer and run the exe.
  1. Set up Accusoft
    a. Before doing anything with Accusoft, go to your Program Files (x86) folder on your C drive and create a new folder called Accusoft.
    b. Now, open the "3rd Party" folder in the source code.
    c. Run the "FormSuite5DotNet.exe" file.
    d. Follow the install wizard, keeping all the defaults EXCEPT the Destination Folder. When you get to a screen that looks like the one below, change the destination to be the Accusoft folder you created in Program Files (x86).
    FormSuiteDefaultDirectory.png
    Note: The destination shown above is the default one and it's NOT the one you want. Be sure to change it to "C:\Program Files (x86)\Accusoft".
    e. Finish the install wizard and wait for the install to complete - it may take a while.
  2. Set up Infragistics
    a. Open "3rd Party\Infragistics" in the source code.
    b. In that directory, you'll find the "Infragistics 2015 keys.txt" file that contains the Infragistics keys we have. You'll need Key 1 for this installation.
    c. Open the "Setups" folder and run the msi you find in there.
    d. Go through the wizard and keep all the defaults. When it asks for your product key, enter Key 1 from part b above. On that page it also asks for a name and organization. The name can be whatever the box defaults to and the organization can be left blank.
    e. You can select Typical when the option comes up and it should complete installing.
  3. Install Certificate
    a. Open "ZonalOCR\ZonalOCR" in the source code.
    b. In that directory, you'll find the "efcKey.pfx" file.
    c. Double-click the key file to begin the installation wizard. Accept all the defaults.
    d. You will be prompted for a password. The password can be found in LastPass in the "Shared-Development" folder in the ".pfx certificate" secure note.
  4. Rebuild the project in Visual Studio using debug mode
  5. Your project should build and not have any issues!

Troubleshooting Zonal Build Issues

It's totally possible that you'll still have some issues after following the steps above. Here are some of the most common issues found when building Zonal on a new machine:

  • Some C# using statements are throwing errors
    Possible Solutions:
    a. Open the pertinent csproj file in notepad and manually change the reference "HintPath" property to the appropriate directory. This is a common issue for the Accusoft sdks. Below is a screenshot of the ZonalOCR.csproj file, with the Accusoft reference HintPath opening tags highlighted so you can see where you should look for invalid or incorrect paths. In your troubleshooting, make sure you look at the specific reference that's throwing the error.
    ZonalOCR_csproj_notepad.png
    b. If the using statement is for log4net, make sure that the log4net NuGet package is installed for the pertinent project.

  • Some XAML assembly references are throwing errors
    Possible Solutions:
    a. Switch the solution to Release mode in VS, rebuild, and then switch back to Debug mode.
    b. I know this sounds dumb, but close and reopen VS.

  • Infragistics key is invalid
    Possible Solutions:
    a. Try Key 2 from the Infragistics 2015 keys.txt file.

  • CDIntfEx reference error
    a. Run the installer at "3rd Party/drivers/drivers6003/Install.exe"
    b. Restart VS

Still Stuck?

Hopefully the above steps and hints were useful, but it's totally understandable if you're still having trouble. The best reference you can go to is DSR, since they were the ones over this project for a long time. If anyone could help you get Zonal running, they could!