Spire.Doc is a professional Word .NET library specifically designed for developers to create, read, write, convert and print Word document files. Get free and professional technical support for Spire.Doc for .NET, Java, Android, C++, Python.

Mon Oct 22, 2018 10:01 am

I download the docx document from outlook. then i open docx document by spire.doc, but i got error message "The argument cannot be null or empty string parameter name: partName".

This error only occurs when some files are opened, what should i do.

I'm coding by C#
error code: Spire.Doc.Document doc = new Spire.Doc.Document(filename, password);
error message: The argument cannot be null or empty string.parameter name: partName

Source Trace: 在 sprᦓ.ᜁ(String A_0, String A_1)
在 spr᧚..ctor(String A_0, String A_1)
在 sprᧉ.ᜂ(spr៱ A_0)
在 spr᧍.ᜀ(spr៱ A_0, Boolean A_1)
在 spr᧍.ᜁ(spr៱ A_0)
在 sprᦸ.ᜅ(MemoryStream A_0)
在 sprᦸ.ᜀ(XmlReader A_0, ParagraphItemCollection A_1, MemoryStream A_2, sprᤫ A_3, CharacterFormat A_4)
在 sprᦸ.ᜀ(XmlReader A_0, ParagraphItemCollection A_1, Boolean A_2, Boolean A_3, spr᠘ A_4)
在 sprᦸ.ᜈ(XmlReader A_0, ParagraphItemCollection A_1)
在 sprᦸ.ᜒ(XmlReader A_0, ParagraphItemCollection A_1)
在 sprᦸ.ᜏ(XmlReader A_0, IDocumentObject A_1)
在 sprᦸ.ᜍ(Stream A_0)
在 sprᦸ.ᜃ(sprᤕ A_0)
在 sprᦸ.ᜁ(Document A_0)
在 sprᦸ.ᜁ(Stream A_0, Document A_1)
在 sprᦸ.ᜁ(String A_0, Document A_1)
在 Spire.Doc.Document.᜕(String A_0)
在 Spire.Doc.Document.LoadFromFile(String fileName, FileFormat fileFormat, String password)
在 Spire.Doc.Document.ᜀ(String A_0, String A_1)
在 Spire.Doc.Document..ctor(String fileName, String password)
在 ClaimReportAutomation.Common.GetWordInfo(String filename, DataTable excelDt, String requestBy, DateTime creationTime, String& hospitalName, String subject) 位置 D:\Project\ClaimReportAutomation\ClaimReportAutomation\Common.cs:行号 259
在 ClaimReportAutomation.Form1.button1_Click(Object sender, EventArgs e) 位置 D:\Project\ClaimReportAutomation\ClaimReportAutomation\Form1.cs:行号 234
在 System.Windows.Forms.Control.OnClick(EventArgs e)
在 System.Windows.Forms.Button.OnClick(EventArgs e)
在 System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
在 System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
在 System.Windows.Forms.Control.WndProc(Message& m)
在 System.Windows.Forms.ButtonBase.WndProc(Message& m)
在 System.Windows.Forms.Button.WndProc(Message& m)
在 System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
在 System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
在 System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
在 System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
在 System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(IntPtr dwComponentID, Int32 reason, Int32 pvLoopData)
在 System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
在 System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
在 System.Windows.Forms.Application.Run(Form mainForm)
在 ClaimReportAutomation.Program.Main() 位置 D:\Project\ClaimReportAutomation\ClaimReportAutomation\Program.cs:行号 19
在 System.AppDomain._nExecuteAssembly(RuntimeAssembly assembly, String[] args)
在 System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
在 Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
在 System.Threading.ThreadHelper.ThreadStart_Context(Object state)
在 System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
在 System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
在 System.Threading.ThreadHelper.ThreadStart()


Thanks.

jintan
 
Posts: 2
Joined: Mon Oct 22, 2018 9:50 am

Mon Oct 22, 2018 10:30 am

Dear,

Thanks for your inquiry.
If you were using an old version, I prefer to recommend that you upgrade to the latest commercial version(Spire.Doc Pack(hot fix) Version:6.10.2 ) to have a try, If the issue still occurs after trying, please provide your input Docx as well as your password to help us further look into your issue. You could send them via email( support@e-iceblue.com).
Besides, we also provide Chinese technical support, you can contact us using Chinese directly if you want.

Sincerely,
Lisa
E-iceblue support team
User avatar

Lisa.Li
 
Posts: 1261
Joined: Wed Apr 25, 2018 3:20 am

Tue Oct 23, 2018 1:33 am

Hi Lisa.Li
我使用的Spire.doc dll已经是最新的6.10.2版本,但依旧出现错误。
因为docx文档涉及项目隐私,而只要修改文档中任何内容,Spire.doc就可以正常打开。所以伙无法将docx文档上传。
我再想其它办法吧,谢谢您提供的帮助.

jintan
 
Posts: 2
Joined: Mon Oct 22, 2018 9:50 am

Tue Oct 23, 2018 1:44 am

Dear,

感谢您的回复,如果您找不到其他好的解决办法,请提供您的文档给我们(support@e-iceblue.com)进行调查,我们非常注重客户的文档机密,绝不外泄或用于其他用途。

Sincerely,
Lisa
E-iceblue support team
User avatar

Lisa.Li
 
Posts: 1261
Joined: Wed Apr 25, 2018 3:20 am

Return to Spire.Doc

cron