Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.gui > #186
| From | "Mary Walker" <mary.walker@THRWHITE.remove-dii-this> |
|---|---|
| Subject | Opening up a file with de |
| Message-ID | <45698ec2$1_3@mk-nntp-2.news.uk.tiscali.com> (permalink) |
| Newsgroups | comp.lang.java.gui |
| Date | 2011-04-27 15:26 +0000 |
| Organization | TDS.net |
To: comp.lang.java.gui Hi, Is it possible, in java, to open up a file (using the JFileChooser class) and then execute it by telling JVM to use the default program. For example in windows, when I double click on a jpg file the image opens up in my default graphics viewer - or if it has a .doc extension Microsoft word opens it up. What I'd like to do is write a Java GUI which can open up a file, make changes to that file programatically and then allow the user to press a button which views the modified file with it's default program. The files I am modifying can be anything (i.e. images, word files, etc) so my java program does not know which program to open the files up with. This is no big deal of course, because all I'm doing at the moment is making the changes to the file and then displaying them by double clicking on them in windows explorer but I'd just like the flexibility of viewing them from my java GUI without having to browse to it again. --- * Synchronet * The Whitehouse BBS --- whitehouse.hulds.com --- check it out free usenet! --- Synchronet 3.15a-Win32 NewsLink 1.92 Time Warp of the Future BBS - telnet://time.synchro.net:24
Back to comp.lang.java.gui | Previous | Next — Next in thread | Find similar
Opening up a file with de "Mary Walker" <mary.walker@THRWHITE.remove-dii-this> - 2011-04-27 15:26 +0000 Re: Opening up a file wit "Thomas Hawtin" <thomas.hawtin@THRWHITE.remove-dii-this> - 2011-04-27 15:26 +0000
csiph-web