如何从Web浏览器控件中检测pdf格式或图像? [英] How to detect pdf format or image from a web browser control?

查看:106
本文介绍了如何从Web浏览器控件中检测pdf格式或图像?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何检测Web浏览器控件上当前是否已加载pdf或任何图像,以及如何将它们下载为pdf或任何图像格式.

谢谢,如果您告诉我答案

How can I detect that pdf or any image is currently loaded on web browser control and also download them as pdf or any image format.

Thanks if you tell me answer

推荐答案

每个文件中都有一个标头,其中包含有关其属性的信息.典型的标头以文件类型签名开头.例如.前两个三个字母将包含BM或PDF等.

因此,如果可以读取文件的标题,您将了解文件的类型.

希望对您有所帮助.
Every file has a header in it, which contains information regarding its properties. Typical header starts with file type signature. eg. First two three letters will contain BM or PDF etc.

So if can read the header of the file, you will get to know what type it is.

I hope that should help.


这篇关于如何从Web浏览器控件中检测pdf格式或图像?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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