Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / August 2005

Tip: Looking for answers? Try searching our database.

SendKeys.Send only runs first time

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
alfred.sehmueller@gmx.de - 17 Aug 2005 07:51 GMT
Hello,

i built a small system-tray application that listens to a hotkey builds
a string and inserts the string to the active application using
SendKeys.Send()

The Problem is - this works only once. The hotkey is still o.k. (i also
copy the string to the clipboard, here I always get the correct string
that contains a timestamp) but sendkeys sends strange characters the
second time:

{}[}}[²
 or
{}[}}[}

Depending on the active application sometimes the second time no string
at all is sent.

Can you please help me with this?

Thanks Alfred
Steve Drake - 17 Aug 2005 14:07 GMT
I havent used sendkey for years, and i have always had problems, if you want
to put some text in somewhere you may be able to use the clipboard and send
the Windows Message the triggers a Paste.

Steve

Hello,

i built a small system-tray application that listens to a hotkey builds
a string and inserts the string to the active application using
SendKeys.Send()

The Problem is - this works only once. The hotkey is still o.k. (i also
copy the string to the clipboard, here I always get the correct string
that contains a timestamp) but sendkeys sends strange characters the
second time:

{}[}}[²
 or
{}[}}[}

Depending on the active application sometimes the second time no string
at all is sent.

Can you please help me with this?

Thanks Alfred
alfred.sehmueller@gmx.de - 17 Aug 2005 16:54 GMT
Thanks for your answer,

the problem is, the users don't wan't to loose there current clipboard.
That's why I thought about sendkeys

Bye Alfred
Steve Drake - 18 Aug 2005 17:07 GMT
You can save and resotre the clip board.

Steve

> Thanks for your answer,
>
> the problem is, the users don't wan't to loose there current clipboard.
> That's why I thought about sendkeys
>
> Bye Alfred
Brendan Grant - 17 Aug 2005 14:41 GMT
Try using SendWait() instead of Send() in order to make sure the first group
of keys was processed by the receiver before sending another group.

Brendan

> Hello,
>
[quoted text clipped - 17 lines]
>
> Thanks Alfred
alfred.sehmueller@gmx.de - 17 Aug 2005 16:55 GMT
Hi Brendan,

thanks for your answer, but this didn't help

Bye Alfred

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.