Hi all, i've done a lot of research out there and cannot find anything like the problem i got atm.
I'm working with C#.
Let me try to explain the situation:
My application is running minimized(trayicon) and controling a Mobily
Computer(MC75) Scanner, so i get a barcode data read by the user.
In the same Mobily Computer(MC75) there's a "WM6 Remote Desktop"
running an application at a remote computer. This application is not
mine and I have no access to it's code.
So after all i need to get the data read by the scanner and send it to the active field at "WM6 Remote Desktop".
The problem:
When i get the scanned data, i'm able to generate some SendKeys events
and it works very nice in a local application(let's say Word Mobile).
However when the same event is used at the application running at "WM6
Remote Desktop" SendKeys fails. Exemple of the failure: scanned data
have 22 characters, only 20 or 21 of them are sent.
Possible solutions that i found, and I was unable to make work properly:
Use SendMessage do deliver the data. (I was stuck getting the handler to the "WM6 Remote Desktop" window).
Use something with clipboard (cut and paste). (Works nice for local
applications, but fails at pasting the code at the application running
at "WM6 Remote Desktop").
Maybe my explanation was a little
confusing as my english is not that good, but i can try to explain it
better if you guys need.
Well guess i've said all my problem, any help, tip, or code sample is appreciated.
Ryan Molina
Loading
Sam HobbsPosted Nov 28, 2009, 12:52 PM
ryan exequielPosted Nov 27, 2009, 2:17 PM
I was trying to use sendmessage method to send the keys, but was stucks with WM_COPYDATA or something like that.
Thanks for your help.
Sam HobbsPosted Nov 24, 2009, 4:03 PM
Sending and receiving keys is not as easy as most people would think, as you are discovering. My advice is to find a different solution if possible. If you are sending keys to simulate the clicking of a button or a menu item, then there are much easier ways to do it. The main reason another way is likely to be easier is reliability; sending keys is unreliable. So what are you doing when you send keys?
One thing you can try is to put a small delay between sending each character.