LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 989
Default troubles with SendKeys

Hello,

I've been having trouble getting SendKeys to act as I would like.

The thing I started to work on is to load data to another application, but I
simplified it down to this, and it still stops:

****************
For i = 1 To 6 Step 1

AppActivate "Untitled - Notepad", True
DoEvents
sendkeys "123456{ENTER}"
DoEvents

Next i
************

When I run that, it starts Notepad, but doesn't enter anything. The code
doesn't stop though... each time that I click on the Excel application
window, or on the VBA code window, if I'm running it that way, it cycles one
more loop through the code, entering the data into Notepad, as it should.

But it only ever does one iteration of the loop at a time, waiting for me to
click on the application window again before it continues.

Ideas as to why?

Thanks,
Mark
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Troubles Jonas Krogh Excel Discussion (Misc queries) 1 October 22nd 09 11:14 AM
Formula troubles Excluxe Excel Discussion (Misc queries) 6 July 16th 07 04:16 PM
SUMPRODUCT troubles David Excel Worksheet Functions 2 July 9th 07 09:04 PM
COM Add-in Troubles Howard Excel Discussion (Misc queries) 0 May 22nd 07 01:59 PM
IF troubles JG Excel Worksheet Functions 6 December 24th 06 04:58 AM


All times are GMT +1. The time now is 04:04 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"