I am trying to convert Word files to PDF.
I am recieving the following error:
<span><h1>Server Error in '/' Application.<hr></h1>
<h2> <i>Couldn't open image file: C:\WINDOWS\TEMP\Aspose.Word.632942744356558452.001.Png</i> </h2></span>
<font face="Arial, Helvetica, Geneva, SunSans-Regular, sans-serif ">
<b> Description: </b>An
unhandled exception occurred during the execution of the current web
request. Please review the stack trace for more information about the
error and where it originated in the code.
<b> Exception Details: </b>System.ApplicationException: Couldn't open image file: C:\WINDOWS\TEMP\Aspose.Word.632942744356558452.001.Png<br><br>
<b>Source Error:</b> <br><br>
<table bgcolor="#ffffcc">
<tr>
<td>
<code></code><pre>Line 169: <br>Line 170: 'Save as PDF<br><font color="red">Line 171: pdf.Save(strFilepath & "\" & PDF_filename)<br></font>Line 172: <br>Line 173: 'Delete temp xml file</pre>
</td>
</tr>
</table>
<br>
<b> Source File: </b> E:\Websites\ACSA_Website2.0\paper_management\submissions\uploadpop2.aspx<b> Line: </b> 171
<br><br>
<b>Stack Trace:</b> <br><br>
<table bgcolor="#ffffcc">
<tr>
<td>
<code></code><pre>[ApplicationException: Couldn't open image file: C:\WINDOWS\TEMP\Aspose.Word.632942744356558452.001.Png]<br> Microsoft.VisualBasic.CompilerServices.Container.InvokeMethod(Method TargetProcedure, Object[] Arguments, Boolean[] CopyBack, BindingFlags Flags) +272<br> Microsoft.VisualBasic.CompilerServices.NewLateBinding.CallMethod(Container BaseReference, String MethodName, Object[] Arguments, String[] ArgumentNames, Type[] TypeArguments, Boolean[] CopyBack, BindingFlags InvocationFlags, Boolean ReportErrors, ResolutionFailure& Failure) +196<br> Microsoft.VisualBasic.CompilerServices.NewLateBinding.LateCall(Object Instance, Type Type, String MemberName, Object[] Arguments, String[] ArgumentNames, Type[] TypeArguments, Boolean[] CopyBack, Boolean IgnoreReturn) +216<br> ASP.paper_management_submissions_uploadpop2_aspx.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in E:\Websites\ACSA_Website2.0\paper_management\submissions\uploadpop2.aspx:171<br> System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +2065851<br> System.Web.UI.Control.RenderChildren(HtmlTextWriter writer) +24<br> System.Web.UI.Page.Render(HtmlTextWriter writer) +26<br> System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +25<br> System.Web.UI.Control.RenderControl(HtmlTextWriter writer, ControlAdapter adapter) +121<br> System.Web.UI.Control.RenderControl(HtmlTextWriter writer) +22<br> System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1896<br></pre>
</td>
</tr>
</table>
<br>
<hr>
<b>Version Information:</b> Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.42
</font>
<br><br><br>I can see the image files that are created when using the SaveFormat.FormatAsposePdf format, but when I try to open them on my local machine it tells me that the file is not the correct format. However, if I open the word document on my desktop (in windows) resave it, and then try to convert it, I have no problems. Please help, this is on a production site accepting hundreds of document uploads.<br>