Dear All,
Please help to achieve the goal as desired.
End Sub
Please help me to get popup message on the basis of following conditions.
1. Already conditional formatting is done in the following ranges(=$C$6:$C$21,$I$6:$I$25 and =$E$6:$E$21,$K$6:$K$25) to fill with red color if duplicate values found. I want to through the message if duplicate values found or if cell color is red, which I already achieved by conditional formatting.
2. message box on all conditions.
3. unless all criteria were not full filled then it won't show the Dialog box for printing.
for better understanding please find the image.
Please help me on this .....
Please help to achieve the goal as desired.
VBA Code:
Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Cancel = False
s = "Want to Continue?"
If Range("Q2") > 0 Then
MsgBox "Please fill !OUT OF OFFICE or IN LEAVE! ", vbOKOnly, ""
End If
If Range("Q6") = Range("Q9") And Range("Q7") = Range("Q10") Then
MsgBox "!No of staff coming is matched with number of picked and dropped staff! Press Ok to continue"
Else
MsgBox "!Check no of staff coming with Picked Staff!", vbOKOnly, ""
End If
If Range("C6:E21,I6:K25").Interior.Color = RGB(255, 0, 0) Then
MsgBox "!Please Check Duplicate Entries!"
End If
If Range("O15") = 0 Then
MsgBox "!!Press Ok to continue and print!!", vbOKCancel, ""
If MsgBox(s, vbYesNo) = vbNo Then Exit Sub
bTemp = Application.Dialogs(xlDialogPrint).Show
End If
End Sub
Please help me to get popup message on the basis of following conditions.
1. Already conditional formatting is done in the following ranges(=$C$6:$C$21,$I$6:$I$25 and =$E$6:$E$21,$K$6:$K$25) to fill with red color if duplicate values found. I want to through the message if duplicate values found or if cell color is red, which I already achieved by conditional formatting.
2. message box on all conditions.
3. unless all criteria were not full filled then it won't show the Dialog box for printing.
for better understanding please find the image.
Please help me on this .....