Relative reference problem
Hi again,
Am Thu, 30 Aug 2018 17:19:28 +0200 schrieb Claus Busch:
Private Sub CommandButton1_Click()
better try:
Private Sub CommandButton1_Click()
Dim varData As Variant
Dim myCell As Range
Set myCell = ActiveCell
With myCell
varData = Range("AG23:AR23")
.Resize(1, UBound(varData, 2)).Value = varData
Application.Goto myCell.Offset(1)
End With
End Sub
Regards
Claus B.
--
Windows10
Office 2016
|