Hello Andrew,
Welcome to JavaRanch. Here are some quick answers to your questions.
I was wondering if this was possible in Java. Yes.
I finally decided that I would have to learn a lot of stuff just to be able to do this. I'm afraid you'll find the same is true in Java, or any other language. There is no quick and easy lay way to do what you are looking to do. You'll need to learn about and understand several different APIs.
I need a browse button where the user can specify the directory and file. Java has a built in class for doing such - javax.swing.JFileChooser - take a look at the
Java API and Sun's
Tutorial on the JFileChooser for more information.
I need to then rename that file from whatever the extension may be to an extension of .xml (foo.txt -> foo.xml) If you
search the
I/O and Streams forum here at the ranch for "copy file" and "rename file" you will find plenty of threads discussing how to do that.
I then need someway of accessing the file and finding "standalone='yes'", then changing it to "standalone='no'" If the document is true XML, you could use an XML parser (either the one built into the JDK or a third party library). Otherwise you could do a more basic search & replace. Again, search the I/O forum and
you should be able to find a starting point. If you run into troubles, make a post stating the issues you are having and someone can help you out.
Lastly, I need to open this new file with it's default program Are you asking how to have your Java Application open the file in its default program?
[ February 06, 2004: Message edited by: Mark Vender ]