S
sklett
I've developed an ERP application that we use internally and works quite
well. I receiving more and more requests from users to print various
transactions, order forms, search results, etc. I haven't decided what the
best way to do this is because I don't have much experience with generating
printable forms.
Early on I knew one of my modules would need to print a clear report so I
used the open source SharpPDF library to generate the PDF. It works well
but is entirely hardcoded and requires a TON of code to generate the PDF.
It also take quite awhile to render the PDF, too long in my opinion.
Another drawback is that I need to save the PDF to disk, then open it and
print it.
Other options I've tried are creating a PDF in acrobat and adding "Acro
Forms" to represent the dynamic data (IE: Invoice #) - I then load the PDF
and using SharpPDF insert text into the form fields. This gives me a sort
of "mail merge" method of creating reports. The main drawbacks are:
- I am restricted to editing the value of form elements
- Can't find a way to create an "item list" - again, think invoice with a
list of line items.
- Still need to save the file to disk in order to display it (or print)
The other option I can think of is using GDI+ to paint the report to the
printer output. This also has the drawback of being "all code" (I can't
edit the style in a visual editor").
So my question is, how do you all generate printable reports/forms/documents
in your applications? Have you found one method to be better than another?
Is GDI+ painting to the printer what most people are doing?
I'm looking for a little guidance here, as it stands now I'm using a couple
different methods and this has resulted in my documents all looking a little
different.
Any suggestions/guidance welcome!
Thanks for reading,
Steve
well. I receiving more and more requests from users to print various
transactions, order forms, search results, etc. I haven't decided what the
best way to do this is because I don't have much experience with generating
printable forms.
Early on I knew one of my modules would need to print a clear report so I
used the open source SharpPDF library to generate the PDF. It works well
but is entirely hardcoded and requires a TON of code to generate the PDF.
It also take quite awhile to render the PDF, too long in my opinion.
Another drawback is that I need to save the PDF to disk, then open it and
print it.
Other options I've tried are creating a PDF in acrobat and adding "Acro
Forms" to represent the dynamic data (IE: Invoice #) - I then load the PDF
and using SharpPDF insert text into the form fields. This gives me a sort
of "mail merge" method of creating reports. The main drawbacks are:
- I am restricted to editing the value of form elements
- Can't find a way to create an "item list" - again, think invoice with a
list of line items.
- Still need to save the file to disk in order to display it (or print)
The other option I can think of is using GDI+ to paint the report to the
printer output. This also has the drawback of being "all code" (I can't
edit the style in a visual editor").
So my question is, how do you all generate printable reports/forms/documents
in your applications? Have you found one method to be better than another?
Is GDI+ painting to the printer what most people are doing?
I'm looking for a little guidance here, as it stands now I'm using a couple
different methods and this has resulted in my documents all looking a little
different.
Any suggestions/guidance welcome!
Thanks for reading,
Steve