Sub
Stundenauswertung()
Dim
Wb
As
Workbook
Dim
WS
As
Worksheet
Dim
vis
As
Long
Dim
i
As
Long
Dim
strOpenFile
As
Variant
strOpenFile = Application.GetOpenFilename(, ,
"Waehlen die aktuelle Stundenauswertungs-Exceldatei aus:"
)
If
strOpenFile =
False
Then
Exit
Sub
Set
Wb = Workbooks.Open(strOpenFile, UpdateLinks:=0,
ReadOnly
:=
False
)
For
Each
WS
In
Wb.Worksheets
If
Not
WS.Name =
"ReadMe"
Then
vis = WS.Visible
WS.Visible = xlSheetVisible
For
i = 30
To
6
Step
-1
If
WS.Cells(i,
"A"
).Text =
"kein Konto"
Then
WS.Rows(i).Delete
Next
WS.Visible = vis
End
If
Next
WS
Windows(
"Makro.xlsm"
).Activate
End
Sub