Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
If Sheets("Sheet2").Range("B5") = "" Or Sheets("Sheet2").Range("B5") = "" Or Sheets("Sheet2").Range("B5") = "" Or Sheets("Sheet2").Range("B5") = "" Then
Cancel = True
MsgBox "Save Cancelled"
Else
Cancel = False
End If
End Sub
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
If WorksheetFunction.CountA( _
sheet1.Range("B5,B10,B38,F38")) < 4 Then
Cancel = True
End If
End Sub
If Application.UserName = "[COLOR=#ff0000]YOU[/COLOR]" Then
Exit Sub
End If
Dim pass As String
pass = InputBox("[COLOR=#ff0000]Enter Admin Password, etc, etc[/COLOR]")
If pass = "[COLOR=#ff0000]1111[/COLOR]" Then Exit Sub