Private Sub Workbook_BeforeClose(Cancel As Boolean)
Dim ans As Variant
    If ActiveSheet.Range("A1").Value = True And ActiveSheet.Range("B2") = "" Then
        ans = MsgBox("A number is required when the role 'xxx' is checked. If number was provided, please enter 'TBD' or 'N/A' as appropriate." _
        & vbNewLine & vbNewLine & "Do you want to save the file anyway?", _
        vbQuestion + vbYesNo, "OPTION")
            If ans = vbYes Then
                Cancel = True
                Application.Dialogs(xlDialogSaveAs).Show
                Exit Sub
            Else
                Cancel = True
                Exit Sub
            End If
    End If
End Sub