Loading...

quicktime-java@lists.apple.com

[Prev] Thread [Next]  |  [Prev] Date [Next]

Re: QTSession.open applet failure Deron Kazmaier Thu Aug 06 16:31:11 2009

Ok, my problem is obviously not a sexy problem to resolve. Everyone here
has probably done this a million times, and your thinking RTFM. Really,
I understand.

So, could someone at least point me in the right direction?

Is it a security issue? Do I need to sign the applet and that is the problem?

Maybe a compile issue? I need to do more than javac QTApplet.java?

Thanks for any help,

Deron


------------------------------------------------------------------------


Hello,

A simple test applet fails, and I'm at a loss as to what I am doing
wrong. I started with some samples, and those didn't work so I've
whittled this down to what seems to me to be a very simple test. No
matter what I do, QTSession.open always fails. This is my first
QuickTime Java applet and I'm hoping it is some simple mistake that
someone can tell me what I did wrong or where I might go to learn an
applicable solution. I can run similar java code locally and it will
output the QT/QTJ version. It fails under Safari and Firefox, but only
Safari dumps useful info to Console log.

Thanks in advance for any help you can provide.

Deron Kazmaier


**** The console log when run under Safari contains:
Applet Init
Applet Start
java.lang.NoClassDefFoundError
   at QTApplet.start(QTApplet.java:17)
   at sun.applet.AppletPanel.run(AppletPanel.java:420)
   at java.lang.Thread.run(Thread.java:613)


*** Firefox just reports status "error: java.lang.NoClassDefFoundError."


**** The QTApplet.java:

import java.applet.Applet;
import quicktime.*;
import quicktime.util.QTBuild;


public class QTApplet extends Applet {

   public void init() {
       System.out.println("Applet Init");
   }

   public void start() {
       System.out.println("Applet Start");

     try {
         QTSession.open( );
         System.out.println ("QT version: " +
QTSession.getMajorVersion( ) + "." + QTSession.getMinorVersion( ));
         System.out.println ("QTJ version: " + QTBuild.getVersion( ) +
"." + QTBuild.getSubVersion( ));
         QTSession.close( );
     } catch (Exception e) {
         e.printStackTrace( );
     }
   }

   public void stop() {
       System.out.println("Applet Stop");
   }

   public void destroy() {
       System.out.println("Applet Destroy");
   }
}

**** Compiled in Terminal with:
javac QTApplet.java


**** The test web page HTML:
<HTML>
<HEAD>
 <TITLE>QTApplet</TITLE>
</HEAD>
<BODY>
   <applet width=100% height=100%
codebase="http://www.pagestream.org/EquusHD" code="QTApplet.class">
       <PARAM name='file'
value='http://www.pagestream.org/EquusHD/videos/EquusHDaboutus.mp4'>
   </applet>
</BODY>
</HTML>



_______________________________________________
Do not post admin requests to the list. They will be ignored.
QuickTime-java mailing list      ([EMAIL PROTECTED])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quicktime-java/alexiscircle%40gmail.com

This email sent to [EMAIL PROTECTED]