Option Explicit
Sub Macro1()
Dim x As Long
Dim y As Long
Dim z As Long
Dim n As Long
Dim o As Long
Dim p As Long
Dim q As Long
x = Sheets.Count
Sheets("Nouvelle Tâche - Arnaud").Copy After:=Sheets(x)
y = Sheets.Count
ActiveSheet.Name = "Tâche N°" & y - 3
Sheets("Tâche N°" & y - 3).Shapes("CommandButton1").Delete
Sheets("Tâche N°" & y - 3).Shapes("CommandButton2").Delete
z = Sheets.Count
Range("B2").Value = "" & z - 2
n = Sheets.Count
formule = CStr(Worksheets("Travaux Arnaud - Récap").Range("R1").FormulaLocal)
Worksheets("Travaux Arnaud - Récap").Range("B" & n + 2).FormulaLocal = Replace(formule, "1", CStr(n - 3))
o = Sheets.Count
formule = CStr(Worksheets("Travaux Arnaud - Récap").Range("T1").FormulaLocal)
Worksheets("Travaux Arnaud - Récap").Range("A" & o + 2).FormulaLocal = Replace(formule, "1", CStr(o - 3))
Hyperlinks.Add Anchor:=Sheets("Travaux Arnaud - Récap").Range("A" & o + 2), Address:="", SubAddress:=" 'Tâche N°" & o - 3 & "'!A1"
Worksheets("Travaux Arnaud - Récap").Range("A" & o + 2).Font.Size = 22
Worksheets("Travaux Arnaud - Récap").Range("A" & o + 2).Font.Underline = xlUnderlineStyleNone
Worksheets("Travaux Arnaud - Récap").Range("A" & o + 2).Font.ColorIndex = 53
p = Sheets.Count
formule = CStr(Worksheets("Travaux Arnaud - Récap").Range("S1").FormulaLocal)
Worksheets("Travaux Arnaud - Récap").Range("C" & p + 2).FormulaLocal = Replace(formule, "1", CStr(p - 3))
End Sub