title: How to deploy a desktop JavaFx 2.0 application correctly using jnlp for 32 and 64 bit?
body: <p>I have a jnlp file for deploying my javafx 2.0 application, however, how do I make sure that the users have the correct javafx runtime (32 or 64 bit depending on the jvm present on the machine) and if not, download it and run the application.</p>
  
  <p>Assuming that the user does not have a javafx runtime currently installed, the problems that I'm facing mostly with a 64 bit machine with either 32-bit, 64-bit or both JRE's are:</p>
  
  <p>1) The Javafx swing deployment guide mentions to use the <code>&lt;jfx:javafx-runtime version /&gt;</code> tag to download the appropriate jfx runtime, but JRE below 1.7 doesn't understand this tag/namespace.</p>
  
  <p>2) If a 32-bit jre is installed on a 64-bit machine, then how do I install my application to the "Program Files(x86)" folder, download and use 32-bit javafx runtime.</p>
  
  <p>3) If a 64-bit jre is installed on a 64-bit machine, then how do I install my application to the "Program Files" folder, download and use 64-bit javafx runtime.</p>
  
  <p>Here is how my jnlp file looks currently: </p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;jnlp spec="1.0+" codebase="file:///C%3A/Program%20Files/HP/Pulse/PulseLite"href="iMonLauncher.jnlp"&gt;
      &lt;information&gt;      
          &lt;title&gt;iMonLauncher&lt;/title&gt;  
          &lt;vendor&gt;Administrator&lt;/vendor&gt;   
          &lt;homepage href="file:///C%3A/Program%20Files/HP/Pulse/PulseLite"/&gt;     
          &lt;description&gt;iMonLauncher&lt;/description&gt;  
          &lt;offline-allowed/&gt;    
      &lt;/information&gt;   
      &lt;security&gt;      
          &lt;all-permissions/&gt;  
      &lt;/security&gt; 
      &lt;resources&gt; 
          &lt;j2se version="1.6+" href="http://java.sun.com/products/autodl/j2se"/&gt;
          &lt;jar href="iMon.jar" size="428419"/&gt;         
           &lt;jar href="lib/ibase-core.jar" size="197029"/&gt;
           &lt;jar href="lib/ibase-fx.jar" size="210175"/&gt;
           &lt;jar href="lib/imonDB.jar" main="true" size="156616"/&gt;
           &lt;jar href="lib/imon-service.jar" main="true" size="73190"/&gt;
           &lt;/resources&gt;
       &lt;application-desc name="iMon" main-class="imon.Main" &gt;
       &lt;/application-desc&gt;
       &lt;update check="always"/&gt;
  </code></pre>
  
  <p> </p>
  
  <p>The codebase changes automatically, to point to the correct program files folder depending on the architecture.</p>
  
  <p>Thanks in advance !</p>