graemeal
Active Member
- Joined
- May 17, 2007
- Messages
- 316
- Platform
- Windows
Hi, I have these 2 macros, is there any way of adding some code to trigger both with one action. I need to change the formulas in 2 columns constantly and would like to do it with one action. I have 7 actual formula changes that I constantly switch back and forth to.
Thanks
Thanks
Code:
Sub Macro9()
'
' Macro9 Macro
'
' Keyboard Shortcut: Ctrl+d
'
Range("J2").Select
ActiveCell.FormulaR1C1 = "=IF(AND(RC[-2]>-0.01,RC[-7]>1000),RC[-6]/RC[-7],0)"
Range("J2").Select
Selection.AutoFill Destination:=Range("J2:J1839")
Range("J2:J1839").Select
Range("A2").Select
End Sub
Code:
Sub Macro10()
'
' Macro10 Macro
'
' Keyboard Shortcut: Ctrl+c
'
Range("L2").Select
ActiveCell.FormulaR1C1 = "=IF(AND(RC[-4]>-0.01,RC[-9]>1000),RC[13]/RC[14],0)"
Range("L2").Select
Selection.AutoFill Destination:=Range("L2:L1839")
Range("L2:L1839").Select
Range("A2").Select
End Sub