@PedroAlves escreveu:
Olá, criei um jbutton para executar um comando CMD.
O resultado não esta aparecendo totalmente. O que fazer para corrigir? Obrigado.
Código:
try {
Process process = Runtime.getRuntime().exec("ipconfig");
Scanner leitor = new Scanner(process.getInputStream());
while (leitor.hasNextLine()) {
//System.out.println(leitor.nextLine());
jTextPane1.setText(leitor.nextLine());
}
} catch (IOException e) {
e.printStackTrace();
}
Mensagens: 5
Participantes: 2