Printing in Windows Forms TreeView
1 Oct 2018 / 1 minute to read
The TreeView Control has in-built support for printing. To print the content of treeview, convert the treeview into the printable document using TreeViewPrintDocument.
TreeViewPrintDocument printDocument = new TreeViewPrintDocument(this.treeViewAdv1);
printDocument.Print();
'Convert the Treeview as printing document
Dim printDocument As New TreeViewPrintDocument(Me.treeViewAdv1)
'Print the contents of the Grid
printDocument.Print()
Print Preview
PrepareTreeImage is used to gets an image that shows the entire tree, not just what is visible on the form.
Was this page helpful?
Yes
No
Thank you for your feedback!
Thank you for your feedback and comments. We will rectify this as soon as possible!
An unknown error has occurred. Please try again.
Help us improve this page