In greenfoot application, use the Share button at top-right and select the Application tab. Fill in the details and click the Share button to create a standalone executable jar file.
Unfortunately, it is no longer possible in recent versions. However, most scenarios work a few versions back. Just download an older version of greenfoot (v26 iirc) and use the share button.