Since you're using File, I'm assuming you're using the Air runtime. To do this, you just need to set the path in the file constructor before you browser; like this:
var file:File = new File(somePath);
file.browse();
The only problem with this is that if you set it as an absolute path (like say, "c:\Users\SomeUser"), it might not work on Macs or Linux computers. Be sure to use some of the File class' built in static properties when you can, like these:
- File.applicationStorageDirectory—a storage directory unique to each installed AIR application
- File.applicationDirectory—the read-only directory where the application is installed (along with any installed assets)
- File.desktopDirectory—the user's desktop directory
- File.documentsDirectory—the user's documents directory
- File.userDirectory—the user directory