View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
John Wilson John Wilson is offline
external usenet poster
 
Posts: 550
Default VBA equivalent to "Return/Enter" Key

Joe,

Try:
Application.SendKeys "{Enter}"
Worked for me. Win XP, XL2000

John

"JMay" wrote in message
news:w9Kgb.45612$AH4.42671@lakeread06...
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As
Boolean)
If ActiveCell.Font.Strikethrough = True Then
ActiveCell.Font.Strikethrough = False
Else
ActiveCell.Font.Strikethrough = True
End If
SendKeys {Enter} <<< This won't take ???
End Sub

Can you help?
TIA


"Joe 90" (remove silly spam) wrote in message
...
Use

Sendkeys {ENTER}
or
Sendkeys ~

See vb help using keyword sendkeys

Cheers

Joe


"JMay" wrote in message
news:USHgb.45210$AH4.15989@lakeread06...
I've got code that is working up to a point **and stops** -- the

screen
(bottom left shows I'm in Edit Mode) - and the cursor is "inside" a

cell --
all that I have to do is manually press enter and it completes.

soooooo
obviously I'd like to incorporate this "last-step" in the code. Can

someone
tell me what I should add to the code to have it complete the update.
TIA,