开发者

What is the best way to create a shortcut hook mechanism for Office

I am looking to create shortcut handler for MS Office.

I am creating an addin with VS2010 for Office 2010. The handler needs to listen to all keyboard events when Word/PowerPoint is active.

Although there is a lot of material for creating application level shortcut handlers, I couldn't find one that was specific to Office.

It would be great if somebody could suggest tech开发者_StackOverflowniques with sample c# code.

Thanks


You need to set a keyboard hook.

Since you're creating an Office addin, you can simply set a normal keyboard hook, which will capture all input in your process.

You can see a C# example here.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜