@juliecooper255 Perhaps give this a try.
VBA Code:
Private Sub Worksheet_Change(ByVal Target As Range)
Dim r As Long
If Target.Cells.Count > 1 Then Exit Sub
If Target.Row < 16 Then Exit Sub
r = Target.Row
Beep
Select Case Target.Column
Case 5
Range("F" & r & ":H" & r).ClearContents
Case 6
Range("G" & r & ":H" & r).ClearContents
Case 7
Range("H" & r).ClearContents
End Select
End Sub
Thanks, i am starting to make sense of syntax as well. Unfortunately, it doesn't work. And testing the code from Georgyboy that was working yesterday, it is not working anymore either. Would other code interfere with it? So far, this is what I have. All work apart from the reset.
Sub Hide_costing()
'
' Hide_costing Macro
'
' Keyboard Shortcut: Ctrl+h
'
Columns("D:K").Select
Selection.EntireColumn.Hidden = True
ActiveWorkbook.Connections("Query - Cost Items").Refresh
Sheets("SOW").Select
Range("B15").Select
End Sub
Sub Print_Proposal()
'
' Print_Proposal Macro
'
' Keyboard Shortcut: Ctrl+p
'
Sheets("Proposal").Select
ActiveWindow.SelectedSheets.Delete
Dim ws As Worksheet
Set ws = Worksheets.Add
ws.Name = "Proposal"
Range("F23").Select
ActiveWindow.DisplayGridlines = False
Sheets("SOW").Select
Columns("B:X").Select
Range("X1").Activate
Selection.Copy
Sheets("Proposal").Select
Columns("A:A").Select
ActiveSheet.Paste
Columns("B:M").Select
Range("M1").Activate
Selection.EntireColumn.Hidden = False
Columns("C:J").Select
Range("J1").Activate
Selection.EntireColumn.Hidden = True
Columns("M:N").Select
Selection.EntireColumn.Hidden = True
Columns("O:S").Select
Selection.EntireColumn.Hidden = True
Columns("V:V").Select
Selection.EntireColumn.Hidden = True
ActiveWindow.ScrollColumn = 2
ActiveWindow.ScrollColumn = 1
Columns("A:A").ColumnWidth = 29
ActiveWindow.SmallScroll Down:=51
Columns("B:B").ColumnWidth = 63.86
ActiveWindow.SmallScroll Down:=40
Columns("A:W").Select
Range("W92").Activate
Application.CutCopyMode = False
ActiveSheet.PageSetup.PrintArea = "$A:$W"
Application.PrintCommunication = False
With ActiveSheet.PageSetup
.PrintTitleRows = ""
.PrintTitleColumns = ""
End With
Application.PrintCommunication = True
ActiveSheet.PageSetup.PrintArea = "$A:$W"
Application.PrintCommunication = False
With ActiveSheet.PageSetup
.LeftHeader = ""
.CenterHeader = ""
.RightHeader = ""
.LeftFooter = ""
.CenterFooter = ""
.RightFooter = ""
.LeftMargin = Application.InchesToPoints(0.7)
.RightMargin = Application.InchesToPoints(0.7)
.TopMargin = Application.InchesToPoints(0.75)
.BottomMargin = Application.InchesToPoints(0.75)
.HeaderMargin = Application.InchesToPoints(0.3)
.FooterMargin = Application.InchesToPoints(0.3)
.PrintHeadings = False
.PrintGridlines = False
.PrintComments = xlPrintNoComments
.PrintQuality = 600
.CenterHorizontally = False
.CenterVertically = False
.Orientation = xlPortrait
.Draft = False
.PaperSize = xlPaperA4
.FirstPageNumber = xlAutomatic
.Order = xlDownThenOver
.BlackAndWhite = False
.Zoom = False
.FitToPagesWide = 1
.FitToPagesTall = 0
.PrintErrors = xlPrintErrorsDisplayed
.OddAndEvenPagesHeaderFooter = False
.DifferentFirstPageHeaderFooter = False
.ScaleWithDocHeaderFooter = True
.AlignMarginsHeaderFooter = True
.EvenPage.LeftHeader.Text = ""
.EvenPage.CenterHeader.Text = ""
.EvenPage.RightHeader.Text = ""
.EvenPage.LeftFooter.Text = ""
.EvenPage.CenterFooter.Text = ""
.EvenPage.RightFooter.Text = ""
.FirstPage.LeftHeader.Text = ""
.FirstPage.CenterHeader.Text = ""
.FirstPage.RightHeader.Text = ""
.FirstPage.LeftFooter.Text = ""
.FirstPage.CenterFooter.Text = ""
.FirstPage.RightFooter.Text = ""
End With
Application.PrintCommunication = True
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True, _
IgnorePrintAreas:=False
Sheets("SOW").Select
End Sub
Sub Budget_Costing()
'
' Budget_Costing Macro
'
' Keyboard Shortcut: Ctrl+b
'
ActiveWorkbook.Connections("Query - Cost Items").Refresh
Application.CommandBars("Queries and Connections").Visible = False
Sheets("SOW").Select
Columns("C:N").Select
Selection.EntireColumn.Hidden = False
Columns("L:M").Select
Selection.EntireColumn.Hidden = True
End Sub
Private Sub Worksheet_Change(ByVal Target As Range)
Dim r As Long
If Target.Cells.Count > 1 Then Exit Sub
If Target.Row < 16 Then Exit Sub
r = Target.Row
Beep
Select Case Target.Column
Case 5
Range("F" & r & ":H" & r).ClearContents
Case 6
Range("G" & r & ":H" & r).ClearContents
Case 7
Range("H" & r).ClearContents
End Select
End Sub