title: Intellij Javafx artifact - how do you make it?
body: <p>I've been trying all day to turn my javafx application into a jar file. I'm using Java 1.7 update 7.</p>
  
  <p>Oracle has <a href="http://docs.oracle.com/javafx/2/deployment/javafx_ant_task_reference.htm">some information</a>, but it just seems scattered all over the place. Intellij is almost doing the job, but I get the following error:</p>
  
  <pre><code>java.lang.NoClassDefFoundError: javafx/application/Application
  </code></pre>
  
  <p>Which seems to say that I need to tell java where the jfxrt.jar is... If I add this jar to my classpath info for the manifest build in intellij - ctrl+shift+alt+s -> Artifacts -> Output Layout tab -> Class Path, then I get another error:</p>
  
  <pre><code> Could not find or load main class com.downloadpinterest.code.Main
  </code></pre>
  
  <p>It seems strange to have to include jfxrt.jar in my class path though...</p>
  
  <p>I've tried to create an ant script as well, but I feel like IntelliJ is 90% of the way there - and I just need a bit of help to figure out why I need to include jfxrt.jar, and why my Main class isn't being found (I'm guessing I need to add it to the classpath somehow?).</p>
  
  <p>Could anyone clue me up as to what is happening? I had a basic gui before which worked fine, but JavaFX seems to be making life complicated!</p>