Instead of SendKeys

  • Thread starter Thread starter George
  • Start date Start date
G

George

Some have suggested that one should never automate an
application using SendKeys, and I agree with the
principle: one doesn't want to accidentally send "Y" to
stray window poised to delete all your files.

However, that observation suggests the question:

What do you do instead of SendKeys to automate a Windows
application that does not otherwise support automation?
(or if it does support automation, it isn't specifically
documented).

I welcome your thoughts.
George
 
What do you do instead of SendKeys to automate a Windows
application that does not otherwise support automation?
(or if it does support automation, it isn't specifically
documented).

Use one that does. Even old applications use DDE, so you may be able to get
away with that.

Tim F
 
Do you have any examples showing DDE with some
miscellaneous windows application?

Not for a long time... Have you tried the help files: on mine I have a
whole page of examples as well as definitions of the functions involved.
For example.

<!--
Dynamic Data Exchange (DDE) Example

The following example establishes a DDE link with Microsoft Excel, places
some values into cells in the first row of a new worksheet, and charts the
values

-->

and so on. Any book on VB or Windows programming will mention it -- or if
it doesn't, throw the book away and buy another one by somebody who knows
what they are talking about.

For details of the Topics and Commands available, you will need the
documentation for the target application.

Hope that helps


Tim F
 
Back
Top