Hello
I have Excel 2010 and I am trying to disable the print funtion until certain cells (AO6, F9, AO9, BD0, etc) are filled out.
I found this code on the website, but does not work for me...
Is there someting i am missing?![]()
Private Sub Workbook_BeforePrint(Cancel As Boolean) If IsEmpty(Worksheets("HRM").Range("bj2")) Then Cancel = True Msg = MsgBox("Please complete cells to continue ", vbOKOnly) Else If Not IsEmpty(Worksheets("HRM").Range("bj2")) Then Cancel = False End If End If End Sub
TY
Bookmarks