How do I open a browser window via Eclipse?
Author: Deron Eriksson
Description: This tutorial describes how to open a browser window using an external tool in Eclipse.
Tutorial created using: Windows XP || JDK 1.5.0_09 || Eclipse Web Tools Platform 1.5.1
One handy thing about EclipseSW is that you can run external programs through Eclipse. To try this, lets open an IE browser window through Eclipse with www.google.com as the page that IE opens at start-up.
To do this, click on the small arrow next to the 'External Tools' icon in your Eclipse perspective and go down to the 'External Tools...' option.
In the External Tools window that opens up, right-click Program and select New:
Give this External Tool configuration a name. Let's call it 'IE - Google'. Next, locate Internet Explorer in the file system via the 'Browse File System' button. After that, specify the web page that you would like IE to open (ie, www.google.com). When you are done with this, click Apply to save the configuration. You can then click 'Run' to open the IE browser with www.google.com as the active page.
A handy thing about this is that now the 'IE - Google' entry appears in the External Tools menu so that you can easily click and run this external tool.
One interesting thing about this technique is that when you close your Eclipse, all of the browser windows that you've opened up via Eclipse will also close. If so desired, you can also close down the browser via Eclipse:
(Continued on page 2)