Forum Discussion
Diana1005
Apr 11, 2024Copper Contributor
Go with use of a macro to other sheet and in the table in this sheet, go to first empty row
Hello, i want to try to create a macro and connect this to a command button. As an employee clicks on this button, the cursor needs to go to the a specifc sheet (f.e. Bezoeken) and in the table ...
HansVogelaar
Apr 11, 2024MVP
For example:
Sub GoToNextRow()
With Worksheets("Bezoeken")
Application.Goto Reference:=.Range("A" & .Rows.Count).End(xlUp).Offset(1), Scroll:=True
End With
End Sub
If you want the next available cell to be selected automatically when the workbook is opened:
In the Visual Basic Editor, in the Project Explorer pane on the left, double-click ThisWorkbook (under Microsoft Excel Objects).
Copy the following code into the ThisWorkbook module:
Private Sub Workbook_Open()
Call GoToNextRow
End Sub