HI Team
need help
below macro is running for all the sheet , could you please help with the code so that it should not run for Sheet1,Sheet2,Sheet3
Sub Test111()
Dim ws As Worksheet
For Each ws In ThisWorkbook.Worksheets
ws.Activate
Range("A500").Select
ActiveCell.FormulaR1C1 = "=R[-497]C"
Range("b499").Select
ActiveCell.FormulaR1C1 = "Tax Liability"
Range("c499").Select
ActiveCell.FormulaR1C1 = "Realised"
Range("B500").Select
ActiveCell.FormulaR1C1 = "=VLOOKUP(R[-1]C,R[-499]C[-1]:R[-6]C[1],3,0)"
Range("C500").Select
ActiveCell.FormulaR1C1 = "=VLOOKUP(R[-1]C,R[-499]C[-2]:R[-2]C[2],4,0)"
Range("C500").Select
Next
End sub
Thanks in advance for help
need help
below macro is running for all the sheet , could you please help with the code so that it should not run for Sheet1,Sheet2,Sheet3
Sub Test111()
Dim ws As Worksheet
For Each ws In ThisWorkbook.Worksheets
ws.Activate
Range("A500").Select
ActiveCell.FormulaR1C1 = "=R[-497]C"
Range("b499").Select
ActiveCell.FormulaR1C1 = "Tax Liability"
Range("c499").Select
ActiveCell.FormulaR1C1 = "Realised"
Range("B500").Select
ActiveCell.FormulaR1C1 = "=VLOOKUP(R[-1]C,R[-499]C[-1]:R[-6]C[1],3,0)"
Range("C500").Select
ActiveCell.FormulaR1C1 = "=VLOOKUP(R[-1]C,R[-499]C[-2]:R[-2]C[2],4,0)"
Range("C500").Select
Next
End sub
Thanks in advance for help