Go4Expert

Go4Expert (http://www.go4expert.com/)
-   Java (http://www.go4expert.com/forums/java/)
-   -   clear console (http://www.go4expert.com/forums/clear-console-t23723/)

onzo 31Oct2010 21:15

clear console
 
i write this funtion to clear the console but it says thet clear not defined for console class


import java.lang.*;
import java.util.*;
import java.io.Console;

public void ClearConsole() {
Console console = System.console();
if (console == null)
System.out.println("Couldn't get Console object !");
console.clear();/////////// getting the error from this line
}

is there any other imports to write ???? or is there any other way to clear the console?
thx

shabbir 1Nov2010 08:39

Re: clear console
 
Duplicate of clear console. Thread closed. Please use the same thread to reply back.


All times are GMT +5.5. The time now is 04:19.