如何在Metro C#应用程序中捕获屏幕 [英] How to capture the screen in a Metro C# app

查看:69
本文介绍了如何在Metro C#应用程序中捕获屏幕的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有人用C#截取Metro应用的屏幕截图吗?还是C ++?还是VB?

Anyone got a snip for grabbing a screenshot of your metro app using C#? Or C++? Or VB?

谢谢...

推荐答案

否,Metro风格的应用程序无法执行此操作.通过设计,他们无法直接与自身以外的其他应用进行交互,包括捕获可能包含其他应用的屏幕截图. Metro风格的应用程序也无法将Xaml元素呈现为位图,因此您无法轻松地为自己的应用程序实现此功能. -罗布

No, there is no way for a Metro style app to do this. By design they cannot directly interact with other apps outside of themselves, including capturing screenshots which may include other apps. There also isn't a way for a Metro style app to render Xaml elements to a bitmap so you can't readily implement this for your own app. --Rob

可在此处找到更多详细信息:

More details are found here : MSDN Forum

我尚未测试此解决方案,但是如果您尝试让您的应用程序按Window键+ PrintScreen,它应该将图片放入图片"文件夹中,您可以通过Windows集成来访问图片(我认为它可能会起作用) )

I haven't test this solution but it might work if you try to let your app press the Window Key + PrintScreen and it should put the picture into the Pictures folder from there you can access the picture through Windows Integration (I think)

这篇关于如何在Metro C#应用程序中捕获屏幕的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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