| 
    
     |  | A1からA1000まで記述するのは大変でしょうから Jakaさんのをそのままいただいて
 
 Private Sub Worksheet_Change(ByVal Target As Range)
 
 If IsEmpty(Target.Value) Then Exit Sub
 If Target.Count > 1 Then Exit Sub
 If Application.Intersect(Target, Range("A1:A1000")) Is Nothing Then Exit Sub
 
 Select Case Target.Value
 
 Case "新規"
 
 With Range(Target.Offset(, 11), Target.Offset(, 100))
 If Application.CountIf(.Cells, "●") <> .Count Then
 MsgBox "エラー"
 End If
 End With
 
 Case "変更"
 
 With Range(Target.Offset(, 11), Target.Offset(, 100))
 If Application.CountIf(.Cells, "●") + _
 Application.CountIf(.Cells, "○") + _
 Application.CountIf(.Cells, "×") <> .Count Then
 MsgBox "エラー"
 End If
 End With
 
 Case "削除"
 
 With Range(Target.Offset(, 11), Target.Offset(, 100))
 If Application.CountIf(.Cells, "×") <> .Count Then
 MsgBox "エラー"
 End If
 End With
 End Select
 
 End Sub
 
 |  |