Northern NY Design
New Member
- Joined
- Sep 24, 2024
- Messages
- 25
- Office Version
- 365
- Platform
- Windows
I am trying to make my MACRO (s) so that when someone clicks it they are prompted to enter "YES". I have read numerous threads on this but I cannot seem to make it work.
Below is the code for my MACRO, please show me where, and what to enter. Thank you in advance.
Sub CLEARROW18()
'
' CLEARROW18 Macro
' Use this MACRO to remove a driver from ROW 18 of the CURRENT DRIVER DATA without removing formulas or harming this spreadsheet set.
'
Sheets("CURRENT DRIVER DATA").Select
ActiveSheet.Unprotect
Range("A20:C20").Select
Selection.ClearContents
Range("E20").Select
Selection.ClearContents
Range("G20:AC20").Select
Selection.ClearContents
Range("AE20:AF20").Select
Selection.ClearContents
Range("AG20:AN20").Select
Selection.ClearContents
Range("AS20:AZ20").Select
Selection.ClearContents
Range("BE20:BL20").Select
Selection.ClearContents
Range("BQ20:BX20").Select
Selection.ClearContents
Range("CC20:CJ20").Select
Selection.ClearContents
Range("CO20:CV20").Select
Selection.ClearContents
Range("DA20:DH20").Select
Selection.ClearContents
Range("DM20:DT20").Select
Selection.ClearContents
Range("DY20:EF20").Select
Selection.ClearContents
Range("EK20:ER20").Select
Selection.ClearContents
Range("EW20:FD20").Select
Selection.ClearContents
Range("FI20:FP20").Select
Selection.ClearContents
Range("C20").Select
Sheets("CURRENT DRIVER DATA").Select
ActiveSheet.Protect DrawingObjects:=True, Contents:=True, Scenarios:=True
End Sub
Below is the code for my MACRO, please show me where, and what to enter. Thank you in advance.
Sub CLEARROW18()
'
' CLEARROW18 Macro
' Use this MACRO to remove a driver from ROW 18 of the CURRENT DRIVER DATA without removing formulas or harming this spreadsheet set.
'
Sheets("CURRENT DRIVER DATA").Select
ActiveSheet.Unprotect
Range("A20:C20").Select
Selection.ClearContents
Range("E20").Select
Selection.ClearContents
Range("G20:AC20").Select
Selection.ClearContents
Range("AE20:AF20").Select
Selection.ClearContents
Range("AG20:AN20").Select
Selection.ClearContents
Range("AS20:AZ20").Select
Selection.ClearContents
Range("BE20:BL20").Select
Selection.ClearContents
Range("BQ20:BX20").Select
Selection.ClearContents
Range("CC20:CJ20").Select
Selection.ClearContents
Range("CO20:CV20").Select
Selection.ClearContents
Range("DA20:DH20").Select
Selection.ClearContents
Range("DM20:DT20").Select
Selection.ClearContents
Range("DY20:EF20").Select
Selection.ClearContents
Range("EK20:ER20").Select
Selection.ClearContents
Range("EW20:FD20").Select
Selection.ClearContents
Range("FI20:FP20").Select
Selection.ClearContents
Range("C20").Select
Sheets("CURRENT DRIVER DATA").Select
ActiveSheet.Protect DrawingObjects:=True, Contents:=True, Scenarios:=True
End Sub