使用iTextSharp的替换PDF文件的文本(不AcroFields) [英] Replace text in PDF file using iTextSharp(not AcroFields)

查看:1701
本文介绍了使用iTextSharp的替换PDF文件的文本(不AcroFields)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的工作与iTextSharp的asp.net C#创建PDF文件。
我创造了许多报告(PDF文件)使用iTextSharp的和一切运作良好。
现在我的客户给我,其中有一些文字这就需要与数据库值代替预先格式化的PDF文件。

I am working on iTextSharp with asp.net C# to create PDF files. I created many reports(pdfs) using iTextSharp and all works well. Now my client gave me pre-formatted pdf file in which there are some text which need to be replaced with database values.

现在我要替换的文字在现有的PDF文件,并​​创建新的。
但正如我GOOGLE了,这是不可能的iTextSharp的。

Now I want to replace text in existing pdf file and create new one. But as I googled, it is not possible in iTextSharp.

我有一些问题,现在
是否真的无法取代PDF文本使用iTextSharp的?
是有它这样做(需要自由无执照)任何其他库或第三方工具?
。如果是这样,请给我一些建议就可以了。

I have some questions now Is it really not possible to replace text in pdf using iTextSharp? Is there any other library or third party tool(free-no licence required) which does so? If so, please give me some suggestion on it.

有关你的信息,我没有AcroFields PDF文件中,也听说过阅读Aspose - PDF文件格式的API(这是不是免费的)。

For your info, I don't have AcroFields in pdf files and also heard about ASPOSE - PDF File format APIs (which is not free).

推荐答案

没有不能用的iText替换现有的文本。

NO you cannot replace the existing text with iText.

PDF是一种显示格式,因此当PDF呈现许多决策都有关页面和字符
布局和positioning.PDF文档所做的是不是一个Word文档本身。

PDF is a display format, so when the PDF is rendered many decisions are made about page and character layout and positioning.PDF document is not a Word document as such.

这篇关于使用iTextSharp的替换PDF文件的文本(不AcroFields)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆