on press

  • Thread starter Thread starter Fraggs
  • Start date Start date
F

Fraggs

Is it possible to create a macro so that when the enter button i
pressed, the workbook is either saved, or saved then closed
 
Fraggs,

You can trap any key with OnKey

Application.OnKey "~", "EnterProc"

Now whenever Enter is pressed, it runs EnterProc

Sub EnterProc()
MsgBox "Hello, dere. This is EnterProc"
End Sub

You sure you want to use the Enter key for this???
 
Back
Top