Friday, 9 August 2013

How to open notepad using Java program

import java.util.*;
import java.io.*;
 
class Notepad {
  public static void main(String[] args) {
    Runtime rs = Runtime.getRuntime();
 
    try {
      rs.exec("notepad");
    }
    catch (IOException e) {
      System.out.println(e);
    }   
  }
}

0 comments:

Post a Comment

Followers