Moyenne avec variable vba
Bonjour,
Si quelqu'un pouvait m'aider... un bout de code qui ne marche pas et je ne comprends pas!
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14
| Sub MOYENNE()
DernLigne = Range("A" & Rows.Count).End(xlUp).Row
DernColonne = Cells(1, Cells.Columns.Count).End(xlToLeft).Column
y = 5
While y < DernColonne + 1
Range(Cells(DernLigne + 1, y)).Value = Application.Average(Range(Cells(2, y), Cells(DernLigne, y)))
Range(Cells(DernLigne + 1, y)).Value = Application.StDev(Range(Cells(2, y), Cells(DernLigne, y)))
y = y + 1
Wend
End Sub |
Merci d'avance