如何从一个pdf的特定颜色的文本# [英] How to get text with a certain color from a pdf c#

查看:398
本文介绍了如何从一个pdf的特定颜色的文本#的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我必须把某个数据库结构中的pdf文件中的数据。这需要我能够从pdf文件中获取某些数据。因为pdf没有任何标签等...我想知道是否可以获得基于颜色的文本。说例如我想要所有的红色文本。或者我想要文档中的所有斜体文本。这是可能在C#吗?或者是否有其他方法来轻松过滤PDF文档中的数据?

I have to put the data from a pdf file in a certain database structure. This requires me to be able to get certain data out of the pdf file. Since pdf hasn't got any tags etc ... i was wondering if it is possible to get text based on a color. Say for example i want all the red text. Or i want all the italic text in the document. Is this possible in C# ? Or is there an other way to easily filter data in a pdf document ?

>

推荐答案

我采用了不同的方法。我将pdf转换为excel文件。这很容易搜索彩色文本

I've taken a different approach. I converted the pdf to an excel file. And this was very easy to search for the coloured text

这篇关于如何从一个pdf的特定颜色的文本#的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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