答案 0 :(得分:1)
将此内容放置在ThisWorkBook中。您不必实际关闭然后打开工作簿,只需通过以下代码F8即可为该会话设置它:
Private Sub Workbook_Open()
Application.OnKey "{ENTER}", "jumpToNextColumn"
Application.OnKey "~", "jumpToNextColumn"
End Sub
这在一个模块中:
Sub jumpToNextColumn()
ActiveSheet.Cells(1, ActiveCell.column + 1).Select
End Sub
或者如tinMan所说:
Sub jumpToNextColumn()
ActiveCell.Next.EntireColumn.Cells(1).Select
End Sub