I am using Excel Visual Basic for Applications (VBA)
I have a Macro that is selecting a set of cells, cutting them and pasting them into a defined cell in another sheet that the user selects. However, I need to have the macro look for empty rows (represented as a 0) in the user-chosen spreadsheet, as data may already be in the spot where it is getting pasted.
My Code:
Sub Button11_Click()
'
' Button11_Click Macro
'
'
Range("A2:K2").Select
Selection.Cut
Sheets(Application.InputBox("Type desired Team")).Select
Range("B4").Select
Sheets("ImporterSheet").Select
End Sub
Basically,
Range(B4).Select
needs to be replaced with
Range(If ActiveCell <> 0 then ActiveCell.Offset(1,0). If ActiveCell = 0 then paste data here)