kann mir jemand zeigen wie man den
nachfolgenden Code so abändert, das die Zellen
A4 bis E5 von Tabelle1 in Tabelle2 kopiert wird.
Option Explicit
Private Sub cmdZeileKopieren_Click()
Dim shTarget As Worksheet
Dim intRow As Integer
Set shTarget = Worksheets("Tabelle2")
Range("A4:E5").Select
intRow = shTarget.Cells(Rows.Count, 2).End(xlUp).Row + 1
Rows(ActiveCell.Row).Copy shTarget.Rows(intRow)
Application.CutCopyMode = False
shTarget.Columns.AutoFit
End Sub
Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Excel.Range, Cancel As Boolean)
Dim shTarget As Worksheet
Dim intRow As Integer
Cancel = True
Set shTarget = Worksheets("Tabelle2").Select
Range("A4:E5").Select
intRow = shTarget.Cells(Rows.Count, 2).End(xlUp).Row + 1
Rows(ActiveCell.Row).Copy shTarget.Rows(intRow)
Application.CutCopyMode = False
shTarget.Columns.AutoFit
End Sub