pdf-generation

winforms report generator for pdf output

别来无恙 提交于 2019-12-08 07:12:54
问题 Need to generate some financial report where the formatting is controlled by the data haven't done reporting in a while but does any reporting support that e.g. based on a flag in the source dataset the row text could be bold the row could have an underlining the report could start a new group header etc. 回答1: There is a component called the ReportViewer for WinForms which ships with Visual Studio. This will do exactly what you need. You can bind it to one or more DataTables and it will

abcpdf 8 .net throwing unhandled exception in w3wp process

天涯浪子 提交于 2019-12-08 06:27:45
问题 I'm trying to use ABCPDF.net 8 to create a pdf from html content. When using the method AddHtml, this works fine. However, I need to take in the styles too, so I need to use AddImageHtml. But using this method causes the w3wp process to throw an exception. When I debug through the code with Reflector the exception seems to come at different places, making me think it is maybe some kind of memory thing... (nice and specific, I know). My abcpdf code is as simple as... global::WebSupergoo

create dynamic invoice bill using mpdf

帅比萌擦擦* 提交于 2019-12-08 06:01:29
问题 MPDF $html=' <body> <div id="page"> <div id="logo"> <a href="http://www.danifer.com/"><img src="./HTML Invoice Template_files/invoice_logo.jpg"></a> </div><!--end logo--> <div id="address"> <p><strong>'.$company.'</strong><br> <a href="mailto:'.$dbobj->getAdminEmail().'">'.$dbobj->getAdminEmail().'</a> <br><br> Transaction # xxx<br> Created on 2008-10-09<br> </p> </div><!--end address--> <div id="content"> <p> <strong>Customer Details</strong><br> Name: '.$dbobj->UserFullName().'<br> Email: '

Programmatically change the color of a black box in a PDF file?

眉间皱痕 提交于 2019-12-08 06:01:17
问题 I have a PDF file generated by Microsoft Word. The user has specified a "highlight" color of black to make the text look like it's a black box (and make the text look like its been redacted). I'd like to change the black boxes to yellow so that the text is highlighted instead. Ideally, I'd like to do this in Python. Thanks! 回答1: Option 1: If a commercial library is an option, you can easily implement this with Amyuni PDF Creator .Net, the C# code would look like this: using System.IO; using

How to Check Boxes in a PDF with fdfgen in Python

≡放荡痞女 提交于 2019-12-08 05:49:01
问题 I'm working on a Python 3.4 project that uses fdfgen and pdftk to fill out a pdf. I can fill in text fields pretty easily. The thing I cannot figure out is how to check a box. Here's the part of my python script: fields = generate_vs300_field_list(answers_dict) # Returns list of tuples of fields and text to be added to pdf fdf = forge_fdf("", fields, [], [], []) logging.debug('Called forge_fdf function. About to open fdf_file.') fdf_file = open(os.path.join(destination_dir, 'vs300.fdf'), 'wb'

How do I embed a source PDF onto an existing page in a PDF?

戏子无情 提交于 2019-12-08 05:48:01
问题 I need to programmatically embed an existing PDF (a small graphic) onto a specfic page on an existing PDF. Using iTextSharp I've been able to add a new page containing this embedded PDF, but what need is to modify an existing page by adding this graphic. Is this possible using iTextSharp or any other PDF-generation libarary? 回答1: I tend to do this sort of thing using Context, which is a Tex-based layout tool that in integrated into the pdftex Tex/Metapost engine. There's a learning curve

Relative File Linking in PDF (Reportlab)

假如想象 提交于 2019-12-08 05:47:14
问题 Is it possible to link to a relative external document that isn't a PDF file from a PDF document? I'm specifically thinking something like an excel spreadsheet. In ReportLab I can add something like Elements.append(Paragraph("<a href=\"pdf://linkedfile.pdf\">File</a>",style)) and it will successfully link to and open linkedfile.pdf in the same folder as my generated PDF, however the documentation doesn't mention any other file types other than pdf and obviously xls:// doesn't work. Does

How to give Background to pdf by dompdf?

坚强是说给别人听的谎言 提交于 2019-12-08 05:33:59
问题 I m using Dompdf to convert Html Page to PDF. As client's requirement pdf should have watermark image at background of document. I have tried many ways in coding and also differnt css style but its not helpful. Is anybody has any idea about it? please Help me out. 回答1: Which version of DOMPDF? With the 0.6.0 release you could use a fixed-position element to act as a watermark. Here's a document shell: <html> <head> <style> #watermark { position: fixed; bottom: 0px; right: 0px; width: 200px;

PDF generation from html pages [closed]

 ̄綄美尐妖づ 提交于 2019-12-08 05:22:52
问题 Closed . This question is opinion-based. It is not currently accepting answers. Want to improve this question? Update the question so it can be answered with facts and citations by editing this post. Closed 6 years ago . To generate pdf file from html page I have used libraries like MPDF , FPDF, DOMPDF etc. In each pdf library I found following issues. mpdf causes unnecessary page breaks FPDF needs more writting. etc When I used DOMPDF it worked fine but large table didn't expanded to next

Outputting PDF with Django as attachment and reload

瘦欲@ 提交于 2019-12-08 04:52:41
问题 I´m using django to generate a pdf and return the response as an attachment in the view. response = HttpResponse(mimetype='application/pdf') response['Content-Disposition'] = 'attachment; filename=somefilename.pdf' Similar to the way described in the doc (http://docs.djangoproject.com/en/dev/howto/outputting-pdf/#write-your-view) What is the best way to reload the page? This didn´t work out (the form triggers the pdf generation): $('#the_form').submit(function(){ location.reload(); }); Thanks