Olá !
Testando o seguinte código:
try {
// Create a URL for the desired page
URL url = new URL("http://www.iol.pt");
// Read all the text returned by the server
BufferedReader in = new BufferedReader(new InputStreamReader(url.openStream()));
String str;
while ((str = in.readLine()) != null) {
System.out.println(str);
}
in.close();
} catch (MalformedURLException e) {
} catch (IOException e) {
}
estou a ter problemas com caracteres esquisitos, em Português.
Por exemplo: Em vez da palavra Informação, recebo informação
Como resolver este problema ? A que se deve ?
Obrigado,
Melhores Cumprimentos,
Pedro Martins
Portugal