How do you write a class to return a file?
So I've read http://java.sun.com/docs/books/tutorial/uiswing/components/filechooser.html But I still do not know how to pass a file to a calling method of another class. How does the FileChooser class retrun the file. Please help.
[245 byte] By [
mransomea] at [2007-11-27 9:46:10]

You mean something like this?
import java.io.File;
public class FileTest {
public File getFile(String path) {
//Example path = "C:\\path\\to\\file.txt"
return new File(path);
}
}