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

Create a PDF from a VB Class

I would like to add code to a VB CLass so I can reuse it in various ASPX pages. My problem is I get an error with the response object (See below). This code works fine in an ASPX page.


If bOpenInBrowser = True Then
doc.Save("Sample.pdf", Response, HttpReadType.Save)
Else
doc.Save("Sample.pdf", Response, HttpReadType.Open)
End If

Thanks.

Ron

1 Reply

SS Sinthuja S Syncfusion Team December 17, 2009 07:41 AM UTC

Hi Ron,

Thanks for your interest in Syncfusion products.

Response object must be passed as a parameter to the function in VB class.

http://help.syncfusion.com/support/Pdf.Windows/Website1.zip

Please try running the above sample and let me know if this helps.

Regards,
Sinthuja.S

Loader.
Live Chat Icon For mobile
Up arrow icon