I am loading an html page into a WebBrowser object in a VB.NET Windows Forms application. The user may make changes to textboxes, dropdowns, etc. on the HTML page displayed in the browser. I want the ability to save the current context to a .pdf file on the local HD. I am able to print using WebBrowser.Print(), which shows the current context, but what ways are possible to get this saved as a PDF file locally?
            Asked
            
        
        
            Active
            
        
            Viewed 2,671 times
        
    1
            
            
        - 
                    There are third party libraries which can save html as pdf. Related question http://stackoverflow.com/questions/564650/convert-html-to-pdf-in-net – Mikael Svenson Mar 10 '10 at 19:00
- 
                    I am looking to save the current context of the browser like I stated. Any comboboxes or any other data on the form that is being changed. Just the HTML to pdf is not what I am looking for. I am looking for the current context of the WebBrowser object. – Matt Mar 10 '10 at 19:29
- 
                    I have code that works fine but this post is so old you may not be interested any longer. If you are interested let me know. – Ed Jenkins Dec 18 '19 at 00:47
2 Answers
1
            
            
        I looked into this not too long ago for a project and basically, the only way to make this happen would be to use a third party component. I know that that isn't what you want to hear, but unfortunately, .NET doesn't have anything PDF related built in. :(
 
    
    
        Jesse Bunch
        
- 6,651
- 4
- 36
- 59
