Private
Sub
Workbook_BeforeClose(Cancel
As
Boolean
)
Dim
i
As
Long
With
Worksheets(
"Tabelle 1"
)
For
i = 46
To
75
If
Not
IsEmpty(.Cells(i,
"B"
))
Then
If
WorksheetFunction.CountA(.Cells(i,
"B"
).Resize(, 12)) < 12
Then
Cancel =
True
Call
MsgBox(
"Bitte alle Felder ausfüllen"
, vbExclamation)
Exit
Sub
End
If
End
If
Next
For
i = 46
To
75
If
Not
IsEmpty(.Cells(i,
"B"
))
Then
If
WorksheetFunction.CountA(.Cells(i,
"B"
).Resize(, xx)) < xx
Then
Cancel =
True
Call
MsgBox(
"Bitte alle Felder ausfüllen"
, vbExclamation)
Exit
Sub
End
If
End
If
Next
End
With
End
Sub