How do I edit a .PDF file while its a resource? - c#

I've been looking around on the web for an answer to a perplexing problem. I'm trying to code a program in C# and I'm looking for a snippet of code that'll take any information a user would input, i.e using a textbox or a check box, and transfer said information onto a .PDF file that I've added as a resource.
Right now I'm using Visual Studio 2008 for my coding, any help would be appreciated.

You can use librairies to create PDF on the fly:
ITextSharp

PDF's are a proprietary format. PDF4Net is a pretty good library for merging information via XDF into PDF's, but you are going to have a lot of trouble trying to do this on your own natively.

Related

Best way to display pdf document in asp.net application

I'm looking for the best way to display pdf document on a website. Surely I need to convert it to jpeg or gif for the browser to handle it. I read few posts but most refer to GhostScript and its pdf2image. But that solution calls for starting a process that would save a copy of pdf doc to the file system and then would have to be loaded back into memory for displaying. Frankly I find it a bit clumsy. For those of you who have done it, what library you used and if you could attach a link to some examples, I'd greatly appreciate it.
I'm developick a web application that helps manage manufacturing process and is accessed fron android tablets. Company has a stockpile of documentation in pdf files that is to be delivered to production managers. I'd love the solution to be akin Crystal Report Viewer contron but I I understand that I have to stick to pdf to image conversion. Please give me some advise here.
My advice is don't over think this.
You can simply add a link to the PDF file, which will open on a new tab.
You can take a look at http://mozilla.github.io/pdf.js/ which will allow you to render a PDF on the client side.
Or if you decide to go with a Ghostscript, you can take a look at http://ghostscriptnet.codeplex.com
By all accounts the PDF Focus .NET library seems to be the best solution. A wrd of advice is to add a cleanup method to the page unload to delete all temporary files that were used to feed source into image controls when displaying pictures on a website.

Server Side HTML to PDF

I'm trying to find a C# library that will allow me to "Print" one of my HTML pages to a PDF file. I can't seem to find out if one currently exists that will allow you to do this. I've found several that will let you build a page, but haven't noticed if one would generate the pdf only based off of HTML.
EDIT: I'm not allowed a budget on this at work so it will need to be an open source/free product. If not I'm aware of iTextSharp and will have to generate the pdf programmatically (which is what I'm hoping to avoid :) )
I've had a lot of luck with ActivePDF WebGrabber. It's kind of odd to use compared to standard managed libraries (ActivePDF is unmanaged), but it gets the job done.
iTextSharp comes with a little companion : XML Worker
For a demo, have a look here
Even though the documentation refers to the Java API, the adaptation to C# should be straightforward.
I've experimented with itextsharp and it works for basic conversion, but gets complicated when you get into styles and formatting. I've also heard wkhtmltopdf is out there as another option.

How to create SWF movie from C# application?

I'm working on C# application where I get some user input, so I'd like to save it as animation to SWF.
I searched the web for some open library to do that, but I've found only dead links. Is there any open library for that?
Thank you in advance.
If you want to create swf files. Then you will need to generate it with adobe's SDK.
http://opensource.adobe.com/wiki/display/flexsdk/Flex+SDK
And there's an open source flash editor project using java + adobe air may helps you.
http://code.google.com/p/minibuilder/
I don't know how I overlooked this project, but there is SwfDotNet.
http://sourceforge.net/projects/swfdotnet/
It seems to be almost what I need, I'll look it through tomorrow.

Creating a PDF from microsoft access database

I would like to create a PDF from the data i have in a microsoft access database. Can someone please tell me what I should use to make this happen? Any tips and steps are appreciated.
One way of doing it is creating a report (you can use CrystalReports) against your AccessDB data, and then exporting that report to PDF.
Other way of doing it is creating a little program in C# and generate a PDF using an Open Source PDF generator like iTextSharp, PDFCreator or Report.NET. There are also a lot of commercial libraries available.
Other way of doing it is creating a little Java program and generate PDF using iText.
Other way of doing it is creating a little insert your favorite programming language here and generate a PDF using a suitable library for it.
try this old link I have used this and it produces PDF direcly fron access full credits to Mr Lebans just follow his clear instructions
http://www.lebans.com/reporttopdf.htm

Highlighting PDFs programatically in .net - are there any APIs or Libraries to generate offset file or is there a better method?

I need to programatically highlight PDFs on the fly, preferrably using the highlight file method.
Are there any .net programming libraries to generate a xml highlight offsets file for a pdf? Doesnt have to be open source or free.
I tried converting PDFBox to a .net DLL using IKVM and it did not work correctly. Im not terribly excited about the memory footprint of the entire java class library in the DLL anyway.
a second option would be to regenerate and highlight the source PDF, if there are any libraries / APIs that will do this to a PDF relatively easily that would work too, but I have not found any in my searches.
thanks in advance.
I dont know if this has solution for your requirement, but this is a good opensource api to work with PDF. I will be so happy if it could help your needs.
http://itextsharp.sourceforge.net/tutorial/index.html

Categories

Resources