Most common error with Generator or Merger .net SDK is that the project .net Framework does not match with the .net correct Generator or Merger .net SDK DLL.
Solution: Set your project to the .net SDK DLL you are using, or use the correct .net SDK for your project. i.e. 2.0 .net framework project should be using Foxit.PDF.20.dll.

This error can cause the error. "system.typeinitializationexception
mscorelib int32 error index"