5 Replies Latest reply on Jul 22, 2008 5:33 AM by 843802

    unable to launch application with webstart

    843802
      Hi all, hope someone can help
      I recently installed j2se 5.0 update 1 and uninstalled my earlier version of 1.4.2_06.
      Since uninstalling the earlier version I am unable to run my application, I get the following error:
      An error occurred while launching/running the application.

      Title: Uploader
      Vendor: Me
      Category: Launch File Error

      Could not parse launch file. Error at line 0.

      This is from the exception tab:
      JNLParseException[ Could not parse launch file. Error at line 0.]
           at com.sun.javaws.jnl.XMLFormat.parse(Unknown Source)
           at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(Unknown Source)
           at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(Unknown Source)
           at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(Unknown Source)
           at com.sun.javaws.LaunchDownload.getUpdatedLaunchDesc(Unknown Source)
           at com.sun.javaws.Launcher.downloadResources(Unknown Source)
           at com.sun.javaws.Launcher.handleApplicationDesc(Unknown Source)
           at com.sun.javaws.Launcher.handleLaunchFile(Unknown Source)
           at com.sun.javaws.Launcher.run(Unknown Source)
           at java.lang.Thread.run(Unknown Source)

      Here is a copy of my jnlp file
      <?php
      header('Content-type: application/x-java-jnlp-file');

      echo '<?xml version="1.0" encoding="UTF-8"?>';

      echo '<jnlp spec="1.0+" codebase="http://www.******.com.au/uploader/fileuploader" href="fileuploader_jnlp.php">';

      echo ' <information>';
      echo ' <title>Uploader</title>';
      echo ' <vendor>Me</vendor>';
      echo ' <homepage href="index.html" />';
      echo ' <description></description>';
      echo ' </information>';

      echo ' <resources>';
      echo ' <j2se version="1.4"/>';
      echo ' <jar href="fileuploader.jar" main="true" />';
      echo ' <jar href="JimiProClasses.jar" />';
      echo ' </resources>';

      echo ' <application-desc main-class="fileuploader.FileUploader">';
      echo ' <argument>http://www.********.com.au/uploader/fileuploader/upload.php</argument>';
      echo ' <argument>25/</argument>';
      //echo ' <argument>100000</argument>';
      //echo ' <argument>thomas:test</argument>';
      echo ' </application>';

      echo ' <security>';
      echo ' <all-permissions/>';
      echo ' </security>';

      echo '</jnlp>';
      ?>

      The application runs fine if I uninstall version 5.0 and revert to 1.4.2_06
      but I would like it to be compatible with newer versions of java.
      P.S. Im not a programer so if you could explain to me in simple terms what Im doing wrong it would be great.
      Thanks in advance
      Dean
        • 1. Re: unable to launch application with webstart
          843802
          well the XML error means you have error in zour XML syntax, i think. maybe the spec changed and now some fields are required (<description> ... </description> is empty?)

          also you spec the jse="1.4"

          maybe jse="1.4+" can help.

          regards, m.
          • 2. Re: unable to launch application with webstart
            843802
            Hi
            I added a description to the jnlp file within the description tags and also changed jse from 1.4 to 1.4+ but still no success.
            • 3. Re: unable to launch application with webstart
              843802
              If webstart can't parse it then it sounds like there's something quirky in the JNLP file that gets generated. Perhaps you could create a static JNLP file (not using PHP) and try that?
              • 4. Re: unable to launch application with webstart
                843802
                Got it working
                well I didnt but with some help from a friend it now works
                changed jnlp file to :
                <?php header('Content-type: application/x-java-jnlp-file'); ?>


                <jnlp spec="1.0+" codebase="http://www.*****.com.au/uploader/fileuploader" href="fileuploader_jnlp.php">

                <information>
                <title>Uploader</title>
                <vendor>Me</vendor>
                <homepage href="index.html" />
                <description></description>
                </information>

                <resources>
                <j2se version="1.4"/>
                <jar href="fileuploader.jar" main="true" />
                <jar href="JimiProClasses.jar" />
                </resources>

                <application-desc main-class="fileuploader.FileUploader">

                <argument>http://www.****.com.au/uploader/fileuploader/upload.php</argument>
                <argument>25/</argument>
                <!-- <argument>100000</argument> -->
                <!-- <argument>thomas:test</argument> -->
                </application>

                <security>
                <all-permissions/>
                </security>

                </jnlp>
                • 5. Re: unable to launch application with webstart
                  843802
                  I'm a programming illiterate having the same problem with the latest java.

                  Unable to Launch Application

                  Exception:
                  JNLParseException[ Could not parse launch file. Error at line 0.]
                       at com.sun.javaws.jnl.XMLFormat.parse(Unknown Source)
                       at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(Unknown Source)
                       at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(Unknown Source)
                       at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(Unknown Source)
                       at com.sun.javaws.Launcher.updateFinalLaunchDesc(Unknown Source)
                       at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
                       at com.sun.javaws.Launcher.launch(Unknown Source)
                       at com.sun.javaws.Main.launchApp(Unknown Source)
                       at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
                       at com.sun.javaws.Main$1.run(Unknown Source)
                       at java.lang.Thread.run(Unknown Source)

                  Wrapped Exception:
                  java.io.EOFException: encoding.error.not.xml
                       at com.sun.deploy.xml.XMLEncoding.decodeXML(Unknown Source)
                       at com.sun.javaws.jnl.XMLFormat.parse(Unknown Source)
                       at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(Unknown Source)
                       at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(Unknown Source)
                       at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(Unknown Source)
                       at com.sun.javaws.Launcher.updateFinalLaunchDesc(Unknown Source)
                       at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
                       at com.sun.javaws.Launcher.launch(Unknown Source)
                       at com.sun.javaws.Main.launchApp(Unknown Source)
                       at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
                       at com.sun.javaws.Main$1.run(Unknown Source)
                       at java.lang.Thread.run(Unknown Source)

                  What am I supposed to do? Java Web Start is supposed to be dummy friendly :(




                  Edit: Problem solved! It seems the file wasn't completely removed and parts of it were corrupted under the java viewer-resources (old cache messing it up). Once removed the problems were gone, so anyone having this problem should check that out :D

                  Edited by: Mr.O on Jul 21, 2008 10:32 PM