But you've missed an important advantage of having a loop control variable. Consider this:
sum += onetoTen[i];
Also, your indentation is inconsistent. It should look like this (open brace on the for() statement line is an option):
int[] onetoTen = {1,2,3,4,5,6,7,8,9,10};
int sum = 0;
for (int i=0; i<10; i++)
{
sum +=onetoTen[i];
System.out.println(sum);
}
And don't use hard coded values (sometimes called "magic numbers") whenever possible. An improved for() loop condition would be:
for ( int i=0 ; i < onetoTen.length ; i++ )