Defines a reusable object that sends output to a printer, when printing from a Windows Forms application.
Questions tagged [printdocument]
289 questions
2
votes
0 answers
C# Cannot Print using PrintDialog when changing print properties after ShowDialog()
The issue occurs when i am using ShowDialog() before setting the Print page properties of my WPF Control (Height ,width ,Number of pages) and then calling PrintDocument() with the desired document, the result of those steps is an empty page printed.…

Barak Shmul
- 21
- 2
2
votes
1 answer
Printing multiple pages using PrintDocument and HasMorePages
I'm trying to print a list of items in a listbox. I have 284 items. About a quarter of them get printed and the rest don't print and at the bottom the last entry is half way cutoff. I read online about keeping track of where you left off and…

Edgar
- 543
- 10
- 20
2
votes
1 answer
Print a document without print preview in windows store apps
I am developing a Windows Store application in Visual Studio 2013 using XAML and C#.
In my project, I have to print a XAML window without having print preview.
Can anybody share the code for the same?
Thanks in advance.

Praveen VR
- 1,554
- 2
- 16
- 34
2
votes
1 answer
PrintDocument.PrinterSettings.Print() Changing default printer
I have the following code, to test out printing to a specific printer. The code sends the print to the correct printer. But I have notices upon completing the print, the systems default printer has changed.
I thought maybe at first maybe the…

Scriven
- 438
- 4
- 12
2
votes
0 answers
printdocument prints too many pages
Help, I have a problem where PrintDocument is printing too many pages for no obvious reason
Unfortunately the error is a bit difficult to reproduce. I have never been able to reproduce it during testing. It only happens when users are printing…

Adagio_Hpt
- 21
- 1
- 6
2
votes
1 answer
How to display all documents in Couchdb using Python
I have recently started using Python. I have a database called student in Couchdb. I have attributes in it like [english, maths, science, total, percentage]. I want to display all the documents from my student database using python. I cant access…

Sam
- 736
- 5
- 15
- 27
2
votes
1 answer
Setting the preferences in SIlverlight PrintDocument
I'm using PrintDocument in Silverlight. I'm printing the Silverlight DataGrid in Silverlight page. When I'm printing it only half of the DataGrid is getting printed....so Can I set the preferences for PrintDocument anywhere. I would like to print it…

Ayyappan Anbalagan
- 11,022
- 17
- 64
- 94
2
votes
1 answer
Print preview does not render images
I am trying to print a page from my Universal Windows Store app.
I currently have it set up that I get a list of tuples, (contains the data to be put on the printed pages: string and ImageSource), and when the user wants to print, a new PrintPage…

vrwim
- 13,020
- 13
- 63
- 118
2
votes
1 answer
Save print document or print preview as image in vb.net
I want to save a print preview to an image file in vb.net.
So far my application generates a print preview with the text the user provides and it prints, but I want to save the printed image to my computer.
I have already googled and saw lots of…

user3125081
- 33
- 1
- 5
2
votes
1 answer
View Datagridview in Print Preview Window
I am creating an application in vb.net. I have a datagridview control in my VB form. I need to view it on printpreview window with the contents in it. I have other control like labels and textboxes in the form and I can view all in printpreview. In…

Rahul S Kumar
- 21
- 1
- 4
2
votes
2 answers
Use PrintDocument to print each row in DataTable to seperate page
I have an application with a DataTable and I need to print each row in the DataTable to a separate page and I'm having a hell of a time trying to get it to work. I've found plenty of posts related to printing more than one page and printing…

Cornelius
- 1,007
- 3
- 22
- 29
2
votes
2 answers
Show all pages of PrintDocument on PrintPreviewControl
I'm having trouble creating multiple pages in a PrintDocument and displaying them within a PrintPreviewControl. I can create a single page easily enough, but stringing together multiple pages is eluding me.
I'm going to eventually draw several…

KarlHungus
- 237
- 4
- 13
2
votes
0 answers
vb.net 2010 PrintDocument Margins not working even if I set the margins
I am reading from a text file and then printing the string using printdocument via vb.net 2010.
Here is my code :
Public Class myPrinter
Friend TextToBePrinted As String
Public Sub prt(ByVal text As String)
Dim psize As New…

user3239332
- 63
- 7
2
votes
1 answer
Is it Possible to so.?
I have searched lot regarding this. But there is no complete solution.
In my form i want to print the document upto the information contained in
my print document page (avoiding paper wasting instead of printing the whole page).
At the same time…

Sathish
- 4,419
- 4
- 30
- 59
2
votes
1 answer
Printing WinForm with controls using PrintDocument component c#
I'm really not interested in having someone else do my job for me, I would really just appreciate a point in the right direction.
I have a couple of Forms that need to be printed. All of them consisting of multiple datagridviews and other controls.…

Herman Vercuiel
- 69
- 2
- 13