How do I set the execute attribute of a file?

John Zukowski

Assuming you are on a platform that supports the attribute, you can call the setExecutable() method of File. Of course, you'll need to wait for Java 6 to do this. Prior versions of standard Java didn't support this.