View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Robert Chapman Robert Chapman is offline
external usenet poster
 
Posts: 9
Default SendKeys {Enter} acts like Return rather than Enter


I'm trying to automate QMF from Excel (to automate the
process of exporting a QMF query as an Excel file). This
involves selecting the QMF application and using Sendkeys
to send all the relevant keystrokes. The only problem is
when I try:

Sendkeys "TRAN", True
Sendkeys "{Enter}", True

TRAN appears onscreen but then Enter isn't pressed. It
appears that Return is pressed since the cursor moves to
the beginning of the line as when you press Return in
QMF. Given that Enter and Return have the same effect in
Excel is there another way I need to refer to Enter to get
this command to work in another application?

Many thanks for any help.

Rob