Option
Explicit
Sub
Daten_zu_Protokoll()
Dim
Test_ID
As
String
Dim
Testbezeichnung
As
String
Dim
Thema
As
String
Dim
Release
As
String
Dim
Sprint
As
String
Dim
Vorbedingung
As
String
Dim
Testschritte
As
String
Dim
Ergebnis
As
String
Dim
Nachbedingung
As
String
Dim
lngLast
As
Long
With
Worksheets(
"Eingabe"
)
Test_ID = .Range(
"C3"
)
Testbezeichnung = .Range(
"C5"
)
Thema = .Range(
"C7"
)
Release = .Range(
"C9"
)
Sprint = .Range(
"C11"
)
Vorbedingung = .Range(
"C13"
)
Testschritte = .Range(
"C15"
)
Ergebnis = .Range(
"C17"
)
Nachbedingung = .Range(
"C19"
)
End
With
With
Worksheets(
"Testprotokoll"
)
lngLast = .Cells(Rows.Count, 1).
End
(xlUp).Row
.Cells(lngLast + 1, 1) = Test_ID
.Cells(lngLast + 1, 2) = Testbezeichnung
.Cells(lngLast + 1, 3) = Thema
.Cells(lngLast + 1, 4) = Release
.Cells(lngLast + 1, 5) = Sprint
End
With
With
Worksheets(Thema)
lngLast = Application.Max(8, .Cells(Rows.Count, 2).
End
(xlUp).Row)
.Cells(lngLast + 1, 2) = Test_ID
.Cells(lngLast + 1, 3) = Testbezeichnung
.Cells(lngLast + 1, 2) = Thema
.Cells(lngLast + 1, 3) = Release
.Cells(lngLast + 1, 4) = Sprint
.Cells(lngLast + 1, 5) = Vorbedingung
.Cells(lngLast + 1, 6) = Testschritte
.Cells(lngLast + 1, 7) = Ergebnis
.Cells(lngLast + 1, 8) = Nachbedingung
End
With
End
Sub