How to generate stylus pen events and pressure in windows?
Asked Answered
P

1

16

I made an external tablet application that is connected to a PC and you can write on it with a stylus pen and the tablet device send point and pressure information to PC and an aplication recives these information through usb connection, now we have point, event and pressure information, I want to know how can I generate and send stylus pen events and messages in windows by an application that created with C#?

I want to simulate mouse and pen events in Windows, I know how can I simulate mouse events by mouse_event function, but what about stylus pen events and its pressure? How can I simulate these events and messages I have to send to Windows?

Also I saw tablet PC API sample codes but they all about receiving pen events not sending pen events to windows, please help me or show me some reference about how to do that.

Thanks :)

Penitential answered 26/6, 2013 at 20:26 Comment(0)
D
1

On a modern Windows operating system you can use input injection. Input injection provides support for programmatically generating and automating input from a variety of devices such as keyboard, mouse, touch, pen, and gamepad. Sample application and info is here https://learn.microsoft.com/en-us/windows/apps/design/input/input-injection

Dispersal answered 27/10, 2022 at 13:1 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.