Invoke an external batch file : WIN32 « SWT JFace Eclipse « Java






Invoke an external batch file

Invoke an external batch file


/*
 * Program example snippet: invoke an external batch file
 *
 * For a list of all SWT example snippets see
 * http://dev.eclipse.org/viewcvs/index.cgi/%7Echeckout%7E/platform-swt-home/dev.html#snippets
 */
import org.eclipse.swt.program.Program;
import org.eclipse.swt.widgets.Display;

public class Snippet105 {

  public static void main(String[] args) {
    Display display = new Display();
    Program.launch("c:\\cygwin\\cygwin.bat");
    display.dispose();
  }

}

           
       








Related examples in the same category

1.Invoke the system text editor on autoexec.bat
2.Place an icon with a popup menu on the system trayPlace an icon with a popup menu on the system tray
3.SWT Ole FrameSWT Ole Frame
4.OLE and ActiveX example snippet
5.Word OLEWord OLE
6.Find the icon of the program that edits .bmp filesFind the icon of the program that edits .bmp files
7.Running a script within IE.Running a script within IE.
8.Reading and writing to a SAFEARRAY
9.Embed Word in an applet
10.OLE and ActiveX example: browse the typelibinfo for a program id
11.OLE and ActiveX example: get events from IE controlOLE and ActiveX example: get events from IE control
12.How to access About, Preferences and Quit menus on carbon