Private Sub CommandButton1_Click()
x = Sheets("Feuil3").ChartObjects.Count
If x <> 0 Then
num = CInt(Right(Sheets("Feuil3").ChartObjects(x).Chart.ChartTitle.Characters.Text, 1)) + 1
inc = x * 230
Else
num = 1
inc = 0
End If
Charts.Add
ActiveChart.ChartType = xlLine
ActiveChart.SetSourceData Source:=Sheets("Feuil1").Range("X2:X10003"), PlotBy:=xlColumns
ActiveChart.HasAxis(xlCategory, xlPrimary) = False
ActiveChart.Location Where:=xlLocationAsObject, Name:="Feuil3"
ActiveChart.HasTitle = True
ActiveChart.ChartTitle.Characters.Text = "Graphique" & num
w = Replace(ActiveChart.Name, "Feuil3", "")
ActiveSheet.Shapes(w).IncrementTop inc
End Sub