Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有没有办法从 C# 中的 pdf 文档(跨越几页)中提取条形码编号。pdf文档基本上是从扫描仪获得的。如果可能的话,我不想使用任何第三方库。
谢谢。
如果您的 PDF 来自扫描仪,那么它很有可能只包含图像。换句话说,它使用 PDF 作为多页的容器。因此,您需要做的是 1)从 PDF 文件中提取图像,2)从光栅图像中加载条形码。
如果您只处理特定的扫描仪,您可以阅读 PDF 规范并编写一个小程序来完成第一部分。但是,我的建议是使用一个好的 PDF 库来做到这一点,因为 PDF 是一种复杂的格式。
对于条码分析,您还应该找到一个条码阅读器程序/库。