将PDF转换为txt文件 [英] Convert PDF into txt file

查看:92
本文介绍了将PDF转换为txt文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我正在开发Web应用程序,因为我必须阅读PDF文件
并将PDF文件转换为txt文件.
如果您认识任何人,请提供代码.
我曾尝试使用Google谷歌搜索,但没有找到合适的解决方案.

谢谢你

Hi All,

I am developing a web application in that I have to read PDF files
and convert PDF file into txt file.
If any one of you know then please provide code.
I have tried googling but haven''t found a proper solution.

Thank You

推荐答案

尝试一下:
try this:
FileInfo file = new FileInfo("c://aa.pdf");  
PDDocument doc = PDDocument.load(file.FullName);          
PDFTextStripper pdfStripper = new PDFTextStripper();
string text = pdfStripper.getText (doc);
richTextBox1.Text = qq;


或参考这个...

将PDF转换为C#文本 [


or refer this...

Converting PDF to Text in C#[^]


为此,您需要一些第三方控件.
看看链接,它会为您提供帮助

点击此处
For that, you need some third party controls.
Have a look to the link, it''ll help you

Click here


我认为您可以从这些国内文章中获得很好的帮助.

[ [ [
I think you may get very good help from these domestic articles.

THIS[^]

THIS[^]

THIS[^]


Please vote and Accept Answer if it Helped.


这篇关于将PDF转换为txt文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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