Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 471
Default Last KeyStroke

Is there a way VBA can tell the last keystroke that a user entered? Here is
what I want to do:
If the user hits enter, instead of going down one row, I wish to go across
one column. But if they press the arrow keys, then I don't want to "alter"
their choice.

So if they press the down arrow, they go down one cell, but if they press
the enter key they go right one cell. Ideas?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 32
Default Last KeyStroke

On Jul 23, 11:03*am, Mike H. wrote:
Is there a way VBA can tell the last keystroke that a user entered? *Here is
what I want to do:
If the user hits enter, instead of going down one row, I wish to go across
one column. *But if they press the arrow keys, then I don't want to "alter"
their choice. *

So if they press the down arrow, they go down one cell, but if they press
the enter key they go right one cell. *Ideas?


Google "OnKey events"...

or check out this

http://msdn.microsoft.com/en-us/libr...ffice.11).aspx
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,939
Default Last KeyStroke

Tools - Options - Edit tab and change Move Selection After Enter to Right.
--
HTH...

Jim Thomlinson


"Mike H." wrote:

Is there a way VBA can tell the last keystroke that a user entered? Here is
what I want to do:
If the user hits enter, instead of going down one row, I wish to go across
one column. But if they press the arrow keys, then I don't want to "alter"
their choice.

So if they press the down arrow, they go down one cell, but if they press
the enter key they go right one cell. Ideas?

Reply
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
Removing a keystroke HeatherJ Excel Discussion (Misc queries) 6 November 30th 09 03:20 PM
One keystroke per cell Steel Keith Excel Discussion (Misc queries) 1 January 12th 07 09:24 PM
Repetitive keystroke Andre Croteau Excel Discussion (Misc queries) 3 October 7th 06 02:20 AM
Shortcut Keystroke for Name Box L Lightner Excel Discussion (Misc queries) 0 July 28th 06 03:03 AM
Keystroke identification Tim[_44_] Excel Programming 0 April 27th 06 11:32 PM


All times are GMT +1. The time now is 10:24 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"