“现场抓取”在Windows中
我想为某些 Windows 应用程序开发一个审核应用程序。我想从 MessageBoxes、Windows、Forms、Selections 等中获取文本,理想情况下我想用 C++ 进行编程。
我已经将 Windows UI 自动化视为一种可能的解决方案,但我有点推迟,因为它说它需要了解我无法了解的部分底层数据结构。或者,我环顾四周,Neo 的 SafeKeys 说它可以防止“现场抓取”,但在搜索它时我找不到任何有关如何完成它的信息。有这方面经验的人可以赐教一下吗?我知道您可以抓取网站等,但我希望抓取应用程序。
任何帮助将不胜感激。
I want to develop an auditing application for certain Windows applications. I want to grab the text from MessageBoxes, Windows, Forms, Selections etc and ideally I would like to program in C++.
I've looked into Windows UI Automation as a possible solution, but am slightly put off as it says it will need to know parts of the underlying data structures which I can't get at. Alternatively, I've looked around and Neo's SafeKeys says that it protects against 'field scraping', but upon searching for it I can't find any information on how it is done. Could someone with experience with this please enlighten me? I'm aware you can scrape websites and the like, but I wish to scrape applications instead.
Any help would be greatly appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
考虑使用可访问性层 MSAA
Look into using the accessibility layer, MSAA
我认为他们正在谈论执行大量 EnumChildWindows() 和 GetWindowText()。
I presume they are talking about doing a lot of EnumChildWindows() and GetWindowText().
无需接近任何数据结构即可完成此操作的简单方法是使用 Abbyy 的 OCR SDK http://www.abbyy。 com/ocr_sdk/ 在应用程序中模拟他们令人惊叹的屏幕截图阅读器的功能。 http://www.abbyy.com/screenshot_reader/ 。有了这项技术,你在屏幕上读到的任何内容都将被捕获为文本,尽管它偶尔会弄乱奇怪的字符。
A simple way of doing this without going near any data structures is to use Abbyy's OCR SDK http://www.abbyy.com/ocr_sdk/ to emulate in an application what their amazing Screenshot reader does. http://www.abbyy.com/screenshot_reader/ . With this technology, nothing you can read on the screen is safe from being captured as text, though it makes a mess of the odd character occasionally.