VC#Sample崩溃

编程入门 行业动态 更新时间:2024-10-26 08:26:46
本文介绍了VC#Sample崩溃的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

那里,

我也开始使用kinect和c#。所以我希望我的问题有一个简单的答案。

iam getting started with kinect and c# too. So i hope there is an simple answer for my question.

我从kinect SDk中获取了SlideshowGestures-WPF样本,并使用来自系统的FindWindow()/ SetForegroundWindow()对其进行了修改。 Windows.Forms获取一个也加载了浏览器窗口(Chrome,Firefox,无论如何)并将其启动。没问题,它可以达到。

I take theSlideshowGestures-WPF sample from kinect SDkand modified it with FindWindow() / SetForegroundWindow() fromSystem.Windows.Forms to get an also loaded browser window (Chrome, Firefox, whatever) and bring it up. No problem, it works up to this.

但是当我开始通过SendKeys.Send("{DOWN}")向浏览器发送密钥时;示例应用程序崩溃并显示以下消息:

But when i start to send an key to the browser via SendKeys.Send("{DOWN}"); the sample applicaton crashes with the message:

System.Windows.Forms.dll中出现未处理的"System.InvalidOperationException"类型异常。

帮助表示赞赏:)

greez

ee

推荐答案

首先要确保您的发送到的应用程序处于活动状态,错误=

没有活动的应用程序可以发送击键。 first be sure the application your sending to is active, the error =

There is not an active application to send keystrokes to.

更多推荐

VC#Sample崩溃

本文发布于:2023-11-27 01:43:45,感谢您对本站的认可!
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:VC   Sample

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!