thedeadzeds
New member
- Joined
- Oct 25, 2011
- Messages
- 37
- Reaction score
- 0
- Points
- 0
- Excel Version(s)
- 2016
Guys,
I have this code and it works fine. Is there a wasy to change it to show
If d6 = "Assistance" then message box to show "J6 must be completed"
If d8 = "Assistance" then message box to show "J8 must be completed"
If d10 = "Assistance" then message box to show "J10 must be completed"
If d12 = "Assistance" then message box to show "J12 must be completed"
If d14 = "Assistance" then message box to show "J14 must be completed"
and so on and so on
Thanks
Craig
Code:
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean) If Worksheets("sheet1").Range("D6").Value = "OK" ThenExit SubElseMsgBox ("You need to complete the task box")End IfEnd Sub
I have this code and it works fine. Is there a wasy to change it to show
If d6 = "Assistance" then message box to show "J6 must be completed"
If d8 = "Assistance" then message box to show "J8 must be completed"
If d10 = "Assistance" then message box to show "J10 must be completed"
If d12 = "Assistance" then message box to show "J12 must be completed"
If d14 = "Assistance" then message box to show "J14 must be completed"
and so on and so on
Thanks
Craig
Code:
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean) If Worksheets("sheet1").Range("D6").Value = "OK" ThenExit SubElseMsgBox ("You need to complete the task box")End IfEnd Sub