Simulate User Input

G

Guest

Hi there,
I'm writing a small app for the PocketPC 2003 using C#. My app should simply
open the Calculator and simulate some key presses (of course im using
P/Invoke). Opening the calc.exe was no problem, but I can't get the 'magic'
input work correctly. By using 'mouse_event' for simulating user input, the
upper left 'Start' button is being pressed (seems strange 'cause I thing the
handle to the Calculator is O.K.) and using 'PostMessage' and 'SendMessage'
have no effect at all.
Can someone help me with this problem please?
 
A

Alex Feinman [MVP]

I'm sure the problem of simulating the stylus input can be helped (I do it
it slightly differently, see
http://www.alexfeinman.com/download.asp?doc=IMSwitch.zip for a sample that
turns on numeric mode on the soft keyboard), but I think you are approaching
it in a wrong way.

If all you need is to drive calc.exe, use keyboard input - by sending
WM_KEYDOWN and WM_KEYUP (or maybe even WM_CHAR) you can do all you need with
the calc
 
G

Guest

Hi Alex,
that's exactly what a newbie like me has been searching for.
Thank you very much.
Kind Regards
Andrej
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top