new line in applet string

I am making an applet that will roll dice and print out the results. The results are printed using a variable string in a paint method, in this case "a". I am having issue making a new line before each set of new rolls and dont know what to do.

Here is the method I am having issues with:

publicvoid roller(int sides,int rolls){

if(rolls>0){

a=a+"On a "+sides+" sided die you rolled: ";

for(int T=0; T<rolls; T++){

int result = (int)(Math.random()*sides+1);

a= a + result;

if(T><rolls-1){a=a+", ";}

repaint();

}

}

}

I have tried \n but that doesnt seem to work.

I have also tried using newline = System.getProperty("line.separator");

but it wont seem to work either.

any and all help is apreciated thanks.

oh and if that was to vague please say >.<

[1518 byte] By [lizardinbootsa] at [2007-11-26 22:01:32]
# 1
Hi, Instead of using a single string, use an array of string and display one under the previous ones.Hope that help,Jack
jack@square6a at 2007-7-10 10:41:40 > top of Java-index,Desktop,Core GUI APIs...