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

how can i convert a url address like "http://google.com" to pdf?

I want to convert a link to pdf, but threw exception。"not found Syncfusion.Pdf.PdfDocument Syncfusion.HtmlConverter.HtmlToPdfConverter.Convert(System.String)"

“System.MissingMethodException”类型的未经处理的异常在 mscorlib.dll 中发生 

其他信息: 找不到方法:“Syncfusion.Pdf.PdfDocument Syncfusion.HtmlConverter.HtmlToPdfConverter.Convert(System.String)”。

public void HtmlToFile()
        {
            //Initialize HTML to PDF converter
            Thread t = new Thread(CreateDocument);
            t.SetApartmentState(ApartmentState.STA);
            t.Start();
            t.Join();
        }
 
        public void CreateDocument()
        {
            HtmlToPdfConverter htmlConverter = new HtmlToPdfConverter();
            //Convert HTML to PDF document
 
            PdfDocument document = htmlConverter.Convert("http://www.google.com");
 
            //Save and close the PDF document
 
            document.Save("Output.pdf");
 
            document.Close(true);
        }






1 Reply

KK Karthik Krishnaraj Syncfusion Team August 15, 2016 07:23 AM UTC

Hi tmzl develop, 
We have created a support incident under your DT account to track the reported issue.                                            
Please log on to our support website for further updates. 
Thanks, 
Karthik. 


Loader.
Live Chat Icon For mobile
Up arrow icon