Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private void jButton3ActionPerformed(java.awt.event.ActionEvent evt) {
- try {
- URL url = new URL("http://dukegames.tk/archivos/changelog.txt");
- URLConnection uc = url.openConnection();
- uc.connect();
- //Creamos el objeto con el que vamos a leer
- BufferedReader in = new BufferedReader(new InputStreamReader(uc.getInputStream()));
- String inputLine;
- String contenido = "";
- while ((inputLine = in.readLine()) != null) {
- contenido += inputLine + "n";
- }
- txt.setText(contenido);
- in.close();
- } catch (Exception e) {
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement