I've been playing around with trying to get my sheet to fill down three formulas every time a new entry is added. And I want it to do it without having to manually run the macro
This is the code I've been playing with
Code
Private Sub Worksheet_Activate()
Dim LastRow As Long
Dim rngFormN As Range
Application.ScreenUpdating = False
With Worksheets("Upgrade Requests")
LastRow = .Range("A" & Rows.Count).End(xlUp).Row
Set rngFormN = .Range("N3:N" & .Cells(.Rows.Count, "A").End(xlUp).Row)
rngFormN.Formula = "=IF(OR(E3="""", I3=""""), """", NETWORKDAYS(E3,I3))"
rngFormN.Offset(0, 1).Formula = "=IF(OR(E3="""", K3=""""), """", NETWORKDAYS(E3,K3))"
rngFormN.Offset(0, 2).Formula = "=IF(OR(K3="""", I3=""""), """", NETWORKDAYS(K3,I3))"
End With
Application.ScreenUpdating = True
End Sub
Display More
I've tried versions of it in selection change event too, but I can't seem to get it to work. It just makes my whole workbook freeze. Any ideas would be a huge help