Private Sub Workbook_BeforeClose(Cancel As Boolean)

    Dim ÀÌ¸§ As Name
    Dim ¼¿ As Range
    
    Const xlRed As Integer = 3
    Const xlBlack As Integer = 1
    
    For Each ÀÌ¸§ In ThisWorkbook.Names
        
        If ÀÌ¸§.Name Like "input*" Then
    
            Set ¼¿ = ÀÌ¸§.RefersToRange
                    
            If IsEmpty(¼¿) Then
        
                ¼¿.Offset(, -1).MergeArea.Font.ColorIndex = xlRed
                Cancel = True
        
            Else
            
                ¼¿.Offset(, -1).MergeArea.Font.ColorIndex = xlBlack
        
            End If
    
        End If
    
    Next
    
End Sub