Loading DOC file - System.ArgumentNullException: 'Value cannot be null. Arg_ParamName_Name'

Using the following code

using GemBox.Document; var document = DocumentModel.Load("Example.doc");

It throws the error:

System.ArgumentNullException: ‘Value cannot be null. Arg_ParamName_Name’

  Message=Value cannot be null. Arg_ParamName_Name
   at System.Text.RegularExpressions.ThrowHelper.ThrowArgumentNullException(ExceptionArgument arg)
   at System.Text.RegularExpressions.Regex.Replace(String input, MatchEvaluator evaluator)
   at .(PropertySet )
   at .(WordDocument ,  )
   at .(Stream , Stream )
   at GemBox.Document.DocLoadOptions.7k4lmxmhj5tk8h83eglk6fss34tasuhn(Stream , String )
   at GemBox.Document.DocumentModel.Load(String path, LoadOptions options)
   at Program.<Main>$(String[] args) in C:\Code\Law365.Azure\Law365.Azure.TestConsole\Program.cs:line 58

Hi Martin,

Please send us your “Example.doc” file so that we can reproduce this issue and investigate it.


How would I go about sending that file?

I don’t want to post it on here - it contains confidential information

You can submit a support ticket or send us an email, and attach your file to the ticket or the message.
Please check our Contact page.