Please let me know the answers to the following:
Is it possible to programmatically fire the touch and gesture events of Windows 7?
Is there any API?
Is it possible to fire the event from a computer without touch screen?
I am looking for something implemented or implementable in C# if possible.
Any help will be much appreciated.
Thank you.
In the Windows 7 pre-beta handed out at PDC 2008, there was an API for injecting gesture input into the input system. However, the API was removed before RTM, and I have it on good authority that this is not a supported scenario for Windows 7.
Related
i'm beginner to creation Windows store apps. Do Windows store apps supports simple way to make custom touch gestures? I searched in MSDN and I found Tablet PC SDK 1.7 but it's written for Windows XP Tablet PC Edition. Thanks in advance
Yes. I'm using the MSGestureEvent in my javascript Windows Store apps but I'm sure there has to be something similar for C# (which I believe is your case)
Check out the Gestures and Manipulations sample: http://code.msdn.microsoft.com/windowsapps/Manipulations-and-gestures-362b6b59. Also see Responding to user interaction (http://msdn.microsoft.com/en-US/library/windows/apps/xaml/hh465397). And if the standard gestures and manipulations aren't enough, you can use Windows.UI.Input.GestureRecognizer to roll your own.
I am developing a WinForms C# application, that needs to know when the computer is not "idle", that is, that a user is actively using it. I can detect keyboard and mouse activity in both the standard desktop and Metro (I think thats what they call it). I can also detect touchscreen activity in the standard desktop - these events are detected as mouse events.
However, using the touchscreen in Metro, none of these events are raised. I have tried this project: http://globalmousekeyhook.codeplex.com/ as well as writing code to hook into the Windows SetWindowsHookEx API with no luck.
I spent some time investigating the WinEvents API too, but can't find anything there that will help.
Anybody know if this can be done? And how?
There happens to be a nice function for that but unfortunately it is C++, so you'll have to P/Invoke it.
I'm developing a c# touch application for windows 8, desktop mode, and i'm unable to find the best approach to do it. My question is: Should I use the existent Windows 7 Touch API c# or there is a new multitouch c# API that can be used to develop windows 8 desktops apps?
I know that windows 8 have legacy support for the win7 touch api, just need some insight and feedback if still is the best and only way to do it.
Does anyone had a previous experience with this problem?
Edited: I found this article: http://software.intel.com/en-us/articles/touch-gestures , basically the UIElement exposes methods that enable touch manipulation. Maybe this is the way to go. Any thoughts?
Thank you.
Windows 8 API has a new API based on WM_POINTER message see http://msdn.microsoft.com/en-us/library/hh454916(v=vs.85).aspx
Windows 7 API has some drawbacks, see http://the-witness.net/news/2012/10/wm_touch-is-totally-bananas/
WM_TOUCHxxx messages are not prone to this problem:
http://social.msdn.microsoft.com/Forums/en-US/ce6d630a-b345-46ac-88ef-773704986d62/touch-responsiveness-issue-how-to-resolve-jagged-nonsmooth-lines?forum=winappswithcsharp
Both the WM_TOUCHxxx and WM_POINTERxxx message will be prone this this problem:
https://web.archive.org/web/20150709083602/https://connect.microsoft.com/VisualStudio/feedback/details/903760/wpf-touch-services-are-badly-broken
If your c# desktop application is using WPF, your only viable option is to implement your own TOUCHDEVICE that fixes these underlying issues, since it appears Microsoft has decided WPF touch is no longer important.
It depends on what actually are your needs in your app.
If you only want new fast ways to rotate and zoom objects, maybe the WPF Manipulation API is all you need.
If, however, you need to handle multiple fingers on your GUI independently, or in a custom way, you simply handle the usual OnTouchDown, OnTouchMove, and other events.
Please note that, however, multi-touch is only available from inside a single window. In other words: you can multi-touch two objects on the same window, but you won't be able to multi-touch two objects that reside on different windows. If you want multi-touch, multi-window funcionality, you need to:
Use .NET 4.7
Change some configuration in your WPF app
I want to use a trackball in my C# .NET application. But I do not want the trackball to be used by Windows as a mouse. When I connect both a trackball and a mouse the are both given control of the cursor.
So there are essentially two questions:
How can the trackball be removed/disabled/coaxed into giving up control of the cursor?
After doing this how can I access the trackball movement information from my C# .NET application.
Thank you!!
Ash
PS: I specifically want trackball support, but am hoping that joystick support will be similar as I may expand to this functionality in the future. Since the joystick does not default to having control of the cursor I can see how this may be different...perhaps easier?
I would think you need to install a special driver that would not identify the mouse as a mouse, but as an input device that streams the movement.
The windows driver kit might help. It says they have a HID device example.
I highly recommend Edward Tse's SDG Toolkit (Single Desktop Groupware Toolkit). I used it several years ago for an application that required multiple mice and monitors.
You can also get the C# source code: http://grouplab.cpsc.ucalgary.ca/cookbook/index.php/Toolkits/SDGSourceCode
first of all I want to tell you that I've searched a lot, and this is not Duplicate question.
My problem is that I want to capture windows events (SystemEvents) when triggered but from windows service application. I've followed this example http://msdn.microsoft.com/en-us/library/microsoft.win32.systemevents.aspx. It says that services need to have message loop (MessagePump in the above example) to process all of these events (Login, logout, power events etc.). The problem is that this example is working great under Windows XP, but for Windows 7 none of these events is caught.
Does anyone have solution to this problem ? I read somewhere that I need to use SENS (System event notification services). Can you point me into the right direction? Thanks.
I've found the solution myself. SENS is unusable under Windows 7. WTS Api is the key. If someone is interested i can post the solution. Thanks anyway :).