Results 1 to 3 of 3
Thread: Output in terminal !
- 11-29-2010, 07:07 PM #1
Member
- Join Date
- Apr 2010
- Posts
- 7
- Rep Power
- 0
Output in terminal !
Hi!
How can I make a output every time change.
F.e.
this makes for every i another line.try{
for(int i=0; i<6; i++){
System.out.println("Test "+(i+1));
Thread.sleep(1000);
}
}catch(Exception e){...}
I want to make it change itself, like % of downloaded in Linux-terminal,
I wanna have in the same line after 1 sec another content !Last edited by pauser; 11-29-2010 at 07:08 PM. Reason: QUOTE
- 11-29-2010, 07:14 PM #2
Senior Member
- Join Date
- Mar 2009
- Posts
- 552
- Rep Power
- 5
try using System.out.print("Test " + (i+1) + "\r"); The carriage return should move back to the start of the line. This question and the answers to it have useful info as well.
If the above doesn't make sense to you, ignore it, but remember it - might be useful!
And if you just randomly taught yourself to program, well... you're just like me!
- 11-29-2010, 07:31 PM #3
Member
- Join Date
- Apr 2010
- Posts
- 7
- Rep Power
- 0
Similar Threads
-
output to terminal instead of console on mac
By firen in forum Advanced JavaReplies: 0Last Post: 06-01-2010, 12:42 PM -
Mac Terminal
By Java8 in forum Other IDEsReplies: 0Last Post: 01-16-2010, 06:19 PM -
Terminal
By dj kourampies in forum New To JavaReplies: 7Last Post: 01-07-2009, 03:57 PM -
VT6530 Terminal Emulator 0.2.2
By JavaBean in forum Java SoftwareReplies: 0Last Post: 03-01-2008, 10:18 PM -
Problem when displays in the terminal
By Felissa in forum Advanced JavaReplies: 2Last Post: 07-01-2007, 02:14 AM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks