We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Error in the Sample App

Hi,
I was trying out one of your samples for creating PDF files. My requirement is to convert an Excel/Word file to PDF. However I could not find a direct method in any of your samples. So I saved the Word file as HTML and tried to convert it to PDF and ran into issues.
When I use your sample code HtmlToPDF it gives the below pasted error if I browse to an html file on my machine.
Can you explain how to fix this, or if there's any other way to conver Excel to PDF.
I am using samples for version 6.2.0.40
Thanks

------------------------
System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(Int32 dwComponentID, Int32 reason, Int32 pvLoopData)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
at System.Windows.Forms.Application.DoEvents()
at Syncfusion.HtmlConverter.HtmlConverter.ToImage(ImageType type)
at Syncfusion.HtmlConverter.HtmlConverter.ConvertToImage(String url, ImageType type)
at Syncfusion.HtmlConverter.HtmlConverter.ConvertToImage(String url, ImageType type, Int32 width, Int32 height, AspectRatio aspectRatio)
at EssentialPDFSamples.Form1.button1_Click(Object sender, EventArgs e)
at System.Windows.Forms.Control.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ButtonBase.WndProc(Message& m)
at System.Windows.Forms.Button.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


1 Reply

SS Sri Subhashini M Syncfusion Team July 14, 2008 11:03 AM UTC

Hi Arif,

Thank you for using Syncfusion product.

Here is the answers for your questions,

1)Word to PDF

I am afraid that I was not able to reproduce the issue. Please look into the sample from the below specified link:

http://www.syncfusion.com/support/user/uploads/Sample_3902f050.zip

Could you please try reproducing it in the above sample or send us the reproducing steps with the couple of PDF files and also your system details so that we could sort out the cause of the issue and provide you a solution?

2)ExcelToPDF

Essential PDF does not have the support to covert the excel to PDF document. This feature will be available in future release.

Please let me know if you need any further assistance.

Regards,
Suba



Loader.
Live Chat Icon For mobile
Up arrow icon