ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Sendkeys VBA and command line (https://www.excelbanter.com/excel-programming/295158-sendkeys-vba-command-line.html)

Bobsa

Sendkeys VBA and command line
 
I'm trying to control an object instantiated from Excel with VBA and
sendkeys to it. But cannot get it to work.

All that happens when I step through it in the VB Editor is that the
sendkeys data are sent to the VBEditor window.

I can fire up a window cmd.exe and activate it with AppActivate but
nothign else goes to it. Anyone help on this one??

Bobsa

Bob Phillips[_6_]

Sendkeys VBA and command line
 
Sendkeys will always send to the active window. When you are in the VBE,
that is the active window, that is where they go. Nothing you can do about
that.

Show the code and tell us what is required and what you get.

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"Bobsa" wrote in message
om...
I'm trying to control an object instantiated from Excel with VBA and
sendkeys to it. But cannot get it to work.

All that happens when I step through it in the VB Editor is that the
sendkeys data are sent to the VBEditor window.

I can fire up a window cmd.exe and activate it with AppActivate but
nothign else goes to it. Anyone help on this one??

Bobsa





All times are GMT +1. The time now is 07:14 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com