Thread: Capture ENTER
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Jake Marx[_3_] Jake Marx[_3_] is offline
external usenet poster
 
Posts: 860
Default Capture ENTER

Hi Ed,

Ed wrote:
I have some code in Worksheet_SelectionChange (ByVal Target As Range)

I want to redirect the activecell to another place when the user hits
ENTER (actually would like it to move the focus to my combobox).

I am not able (or don't understand) how to accomplish this. I have
tried the Target = 13 in other places in my code with comboboxes and
keydown and it works, but it doesn't work in this sub. Any
suggestions?


The SelectionChange event will fire when the user's selection changes from
one cell or range to another. The Target argument is a Range object that
references the newly-selected range. So I don't think you need to trap the
Enter key - I think you could just trap the event and move to your ComboBox
based on the new selection.

--
Regards,

Jake Marx
www.longhead.com


[please keep replies in the newsgroup - email address unmonitored]