From: "Doug Cox" <[EMAIL PROTECTED]>
Subject: Re: Direct Connection Between Applet and RealPlayer

I believe your problem is that JSObject is part of the Netscape Java package
and you are running an IE browser.

The exception you noted:
     >java.lang.ClassCastException: netscape/javascript/JSObject

shows that the IE VM isn't sure how to cast a Netscape class into the IE
space.

Doug


-----Original Message-----
From: RealForum <[EMAIL PROTECTED]>
Date: Tuesday, December 21, 1999 9:18 PM
Subject: Direct Connection Between Applet and RealPlayer


 >From: [EMAIL PROTECTED]
 >Subject: Direct Connection Between Applet and RealPlayer
 >
 >Has anyone been successful in getting a Java applet to directly
control/monitor
 >a RealPlayer viewer in IE? I've been successful in doing so when I view the
 >page
 >in Netscape, but when I do so in IE, I get an access violation error.
 >Here's the
 >error:
 >
 >java.lang.ClassCastException: netscape/javascript/JSObject
 >      at foo.init (foo.java:16)
 >      at com/ms/applet/AppletPanel.securedCall0 (AppletPanel.java)
 >      at com/ms/applet/AppletPanel.securedCall (AppletPanel.java)
 >      at com/ms/applet/AppletPanel.processSentEvent (AppletPanel.java)
 >      at com/ms/applet/AppletPanel.processSentEvent (AppletPanel.java)
 >      at com/ms/applet/AppletPanel.run (AppletPanel.java)
 >      at java/lang/Thread.run (Thread.java)
 >
 >And here's the Java that causes it:
 >
 >      System.out.println( "*** init" );
 >      JSObject win = JSObject.getWindow( this );
 >      System.out.println( "win=" + win );
 >      JSObject doc = (JSObject )win.getMember( "document" );
 >      System.out.println( "doc=" + doc );
 >      rap = (RAPlayer )doc.getMember( "ImageWindow" ); // ERROR
 >      System.out.println( "rap=" + rap );
 >      rap.AdviseG2( this );
 >
 >Again, this run of code works just fine in Netscape. And using my
JavaScript
 >bridge I posted earlier, I'm able to communicate between the two components
on
 >both browsers. I'm just curious if I can do away with my JavaScript bridge
 >code.
 >
 >Brad
 >


*******************************************************
The RealForum is an email discussion group focused on using RealNetworks
products. The RealForum is a place to post messages about the best methods
for creating content using RealNetworks technologies and the planning and
implementation of streaming-media web sites.  Archives of RealForum can
be found at http://realforum.real.com

If you ever want to remove yourself from this mailing list,
you can send mail to <[EMAIL PROTECTED]> with the following
command in the body of your email message:

    unsubscribe realforum

or from another account, besides the address you subscribed with:

    unsubscribe realforum <[EMAIL PROTECTED]>

Reply via email to