Html class with applet tag support ?

Hello,
I would like to load in a swing application, an html file which contains the tag 'applet'. JEditorPane doesn't support it.
Anyone know of an another class ?
Thanks
Nathalie OBADIA

If all else fails you can get the source code and look to see how appletviewer is implemented. It probably just calls some internal sun java classes.

Similar Messages

  • HTML Page with Applet in JEditorPane

    Hi,
    I have a JEditorPane in which i want to show a HTML page which has an Applet embedded in it. Is there anyway that I can do this as if I just give the URL of the HTML file it gives me a text field with applet tag written in it.
    Or is there any other way that I can embed an Applet in my application in one of Swing components.
    Thanks in advance,

    Update:
    You may want to extend HTMLEditorKit:
    public class MyHTMLEditorKit extends HTMLEditorKit() {
        static ViewFactory viewFac = new HTMLFactory(){
           public View create(Element el) {
              if(el.getName().equalsIgnoreCase("APPLET")) {
                  Applet app = ...; // create applet from other attributes
              else return super.create(el);
    }Check this out. I don't know whether applet elements are included in the parsed document; nevertheless, check it out.
    Fritz

  • Window with applet tag gains focus prior to new window browser window

    setup a :
    1. sample index.html page:
    <HTML>
    <HEAD>
    <script>
    var _load=function(){window.open('test.html');};
    window.attachEvent("onload", _load);
    </script>
    </HEAD>
    <BODY>
    <applet code=Index name=Index width=1 height=1 align=baseline>
    </BODY>
    </HTML>
    2. and child test.html window of the above (opened during onload event)
    <HTML>
    <HEAD>
    <TITLE>1</TITLE>
    <script>
    var _load=function(){window.focus();};
    window.attachEvent("onload", _load);
    </script>
    </HEAD>
    <BODY>
    TEST PAGE
    </BODY>
    </HTML>
    when a test.html page is opened focus is temporarily shifted back to the index.html page and
    only later back to the test.html page (window.focus()) call in that page sets the focus, not always
    suceeds, a further code is required to do a retry)
    when the applet is removed from the index.html page, problem goes away, it is if the applet tag
    has priority in terms of window focus
    byproduct of this is also annoying flicker, (while the focus is shifted between index.html and test.html page)
    this problem is only happening with SUN JVM (and I dont know if its a defect or by design)
    SUN JVM tested:
    Java(TM) Plug-in: Version 1.4.2_03
    Using JRE version 1.4.2_03 Java HotSpot(TM) Client VM
    suggestions, workarounds? appreciate in advance

    tested following matrix of browser/VM
    Platform Result:
    MS IE and Microsoft (R) VM for Java, 5.0 Release 5.0.0.3810 (with success, no focus problems)
    MS IE and Java(TM) Plug-in: Version 1.4.2_03 (focus problems, in the case of
    two applets one coded on the
    main page the other on the pop-
    up window)
    Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax)
    Plug-in: Version 1.4.2_03 Using JRE version 1.4.2_03 Java HotSpot(TM) Client VM
    (focus problems, in the case of one applet on
    the main page or in the case of two applets
    one coded on the main page the other on the
    pop-up window)
    Please see revised test case source code (to support above configurations, as well inclusion of the second
    applet to address discrepency in behaviour between Mozilla and IE (with SUN JVM)
    <HTML>
    <HEAD>
    <script>
    String.prototype.contains=function(s){return(this.toLowerCase().indexOf(s.toLowerCase())!=-1);};
    var u_n=navigator;
    var u_agt=u_n.userAgent.toLowerCase();
    var u_MSIE=(u_agt.contains("msie"));
    var _load=function(){window.open('test.html');};
    if (u_MSIE)
    window.attachEvent("onload", _load);
    else
    window.addEventListener("load", _load, false);
    </script>
    </HEAD>
    <BODY>
    <applet code=Index name=Index width=1 height=1 align=baseline>
    </BODY>
    </HTML>
    <HTML>
    <HEAD>
    <TITLE>1</TITLE>
    <script>
    String.prototype.contains=function(s){return(this.toLowerCase().indexOf(s.toLowerCase())!=-1);};
    var u_n=navigator;
    var u_agt=u_n.userAgent.toLowerCase();
    var u_MSIE=(u_agt.contains("msie"));
    var _load=function(){window.focus();};
    if (u_MSIE)
    window.attachEvent("onload", _load);
    else
    window.addEventListener("load", _load, false);
    </script>
    </HEAD>
    <BODY>
    TEST PAGE
    <applet code=Test name=Test width=1 height=1 align=baseline>
    </BODY>
    </HTML>
    Index.java source code:
    public class Index extends Applet {
    public synchronized void init() {
    public synchronized void start() {
    public synchronized void stop(){
    public synchronized void destroy(){
    Test.java source code:
    public class Test extends Applet {
    public synchronized void init() {
    public synchronized void start() {
    public synchronized void stop(){
    public synchronized void destroy(){

  • How to make pack200 work with applet tag ?

    Hello All,
    Sorry for the cross-post.
    I tired getting the advise on java.net forum but with no success. Can someone here please help with this or direct me to right direction.
    I am trying to use the pack200 compressed jars for my Object/Applet tag, but not sure how to go about using it.
    I have followed the instructions for jarsigned pack200 jars.
    http://java.sun.com/j2se/1.5.0/docs/guide/deployme.../deployment-guide/pack200.html
    But now how do i use them in my Object tag, what should i name the files in my cache_archive parameter :
    example:
    something like :
    <PARAM NAME = CACHE_ARCHIVE VALUE = "final.jar" />
    or :
    <PARAM NAME = CACHE_ARCHIVE VALUE = "final.jar.pack.gz" />
    renaming : final.jar.pack.gz --> final.jar ??
    I tried both the above options but none of them works.
    network: Wrote URL http://myserver.net/Stream/lib/final.jar to File C:\Documents and Settings\I025204\Application Data\Sun\Java\Deployment\cache\6.0\60\366763c-2a096009-temp
    java.util.zip.ZipException: ZIP file must have at least one entry
    at java.util.zip.ZipOutputStream.finish(Unknown Source)
    at java.util.zip.DeflaterOutputStream.close(Unknown Source)
    at java.util.zip.ZipOutputStream.close(Unknown Source)
    at com.sun.deploy.net.HttpDownloadHelper.download(Unknown Source)
    at com.sun.deploy.cache.Cache$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.sun.deploy.cache.Cache.downloadResourceToCache(Unknown Source)
    at com.sun.deploy.cache.DeployFileOutputStream.close(Unknown Source)
    at sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.close(Unknown Source)
    at java.io.BufferedInputStream.close(Unknown Source)
    at sun.plugin.PluginURLJarFileCallBack.downloadJAR(Unknown Source)
    at sun.plugin.PluginURLJarFileCallBack.access$000(Unknown Source)
    at sun.plugin.PluginURLJarFileCallBack$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at sun.plugin.PluginURLJarFileCallBack.retrieve(Unknown Source)
    at sun.net.www.protocol.jar.URLJarFile.retrieve(Unknown Source)
    at sun.net.www.protocol.jar.URLJarFile.getJarFile(Unknown Source)
    Do i need to add something more .
    I am only allowed to use the below:as its the corporate policy for now.
    Java Plug-in 1.6.0_05
    Using JRE version 1.6.0_05 Java HotSpot(TM) Client VM
    Can someone please help me how to get the pack200 work in the Object tag ?
    Please advise.
    Thanks,

    InputStream in = sc.getResourceAsStream("application.jar.pack.gz");
            OutputStream out = response.getOutputStream();
            if (in != null) {
                try {
                    sendOut(in,out);
                } catch (IOException ioe) {
                    if (ioe.getMessage().compareTo("Broken pipe") == 0) {
                        sc.log("Broken Pipe while writing");
                        return;
                    } else  throw ioe;
            } else response.sendError(response.SC_NOT_FOUND);
    private void sendOut(InputStream in, OutputStream ostream)
                     throws IOException {
            byte buf[] = new byte[8192];
    System.out.println("send jar file");
            int n = in.read(buf);
            while (n > 0 ) {System.out.println(n);
                ostream.write(buf,0,n);
                n = in.read(buf);
            ostream.close();
            in.close();
        }the servlet code is above
    u should conifgure the servlet in the web.xml for urlmapping *.jar
    <servlet-mapping>
          <servlet-name>jarService</servlet-name>
          <url-pattern>*.jar</url-pattern>
        </servlet-mapping>where jarService is the name of the pack200 sevice servlet ContentType.java
    Edited by: kartheepanmirra on Jun 17, 2009 12:17 AM
    Edited by: kartheepanmirra on Jun 17, 2009 3:06 AM

  • How to get exact height of HTML line with SUB tag in JTextPane?

    Hi, this is my first post. I`ve been searching forum for an answer for a week, but didn`t find one.
    I have HTMLDocument inside JTextPane(exacty inside my class that extends it - MyTextPane). I want to do some custom painting in JTextPane so I need to be able to know exact pixel witdh for each line in the document. Easy except one thing, when I use SUB tag the width of the line cannot be simply calculated using FontMetrics, because I don`t know if the text inside SUB tag has lower font size and I don`t know its Y offset to normal line.
    I tried get these information from HTMLDocument using attributes from leafElements representing lines, but there seems to be a problem too.
    I pass this text:
    "(1) Line<SUB>jW</SUB><BR>(2) TextB"
    to setText method of MyTextPane, this method is overriden so it changes text Font
    public void setText(String s) {   
      super.setText(s);   
      setJTextPaneFont(this, new Font("Arial",Font.PLAIN,36), Color.black);
    }This is how the Element Structure looks like:
    Format is Element +": "+elementText+"|"+fontFamily+" "+fontSize
    BranchElement(html) 0,22: \n(1)?LinejW (2)?TextB\n|Monospaced 12
    ---BranchElement(head) 0,1: \n|Monospaced 12
    ------BranchElement(p-implied) 0,1: \n|Monospaced 12
    ---------LeafElement(content) 0,1: \n|Arial 36
    ---BranchElement(body) 1,22: (1) LinejW (2) TextB\n|Monospaced 12
    ------BranchElement(p-implied) 1,22: (1) LinejW (2) TextB\n|Monospaced 12
    ---------LeafElement(content) 1,9: (1) Line|Arial 36
    ---------LeafElement(content) 9,11: jW|Arial 36 <-----------THIS IS THE LOWER INDEX
    ---------LeafElement(content) 11,12: |Arial 36 <-----------THIS IS just space character '\u020'
    ---------LeafElement(content) 12,21: (2) TextB|Arial 36
    ---------LeafElement(content) 21,22: \n|Arial 36
    The height of Arial 36 is according to FontMetrics 43(and it really is), but height of the lowerIndex is just 40 pixels(on the screen), not 43 as I would expect. And I still dont have offset, where does the lower index starts paint itself.
    Is there any problem with my setText method, so that it changes font style for LOWER INDEX?
    I am using JTextPane as notEditable, with just one font style for entire document.
    Any suggestion?

    Is there any other way to get these information. I just found that I need that information before I put text it in the document.
    For example I am would like to generate lines:
    paragraph1 - text1
                             text2
    paragraph2 - text1
                             text2
                             text3
    paragraph3<SUB>some note</SUB> - text1
                                                                           text2
    normal text line
    I know what font line will be and I know its AttributeSet. I am trying to get appropriate number of spaces (or left indent) for text2,text3...lines. Then I will pass that string to setText method of JTextPane.
    I am unable to get appropriate width for "paragraph3<SUB>some note</SUB> - ", since text in SUB tag uses probably different font size.
    I am really sorry to bother again. I will think twice what I need before I posting.
    You`ve been very helpful so far Stas.
    Thanks.

  • Is there a way to include html link with applet?

    I am thinking of writing an applet that would be useful to others, which I would provide for free. In return I would want a link from the pages that use the applet. It is important that the link is search engine friendly, a pure href html link that will provide google page rank to me.
    Is there a way to include such a link with an applet so that it can't be removed?

    No. You can't force other sites to change their content.

  • applet tag vs Object tag

    As per W3Schools HTML applet tag is not supported in HTML5. Need to use <Object> tag instead of <applet> tag.
    For more details follow this link: http://www.w3schools.com/tags/tag_applet.asp
    http://dev.w3.org/html5/spec/obsolete.html#the-applet-element
    Point 11.2 Non-conforming features
    So, I go ahead and the change the code as below depicted.
    Below code that is working with <APPLET> tag:
    +<Applet+
    style    = "position:absolute;border:0px;left:184;top:95;height:180;width:364;"
    code     = "jtreeviewapplet.JTreeViewAppletMain.class"
    name     = "TreeView"
    id       = "TreeView"
    hspace   = "0"
    vspace   = "0"
    align    = "top"
    archive  = "/Project/HTML/ABC/XYZ.jar,/Project/HTML/ABC/ABC.jar"
    MAYSCRIPT>
    +<PARAM NAME="onSelected" VALUE="onSelect_Handler">+
    +<PARAM NAME="onFinishNormalize" VALUE="onFinishNormalize_Handler">+
    +</Applet>+
    Here is the snippet, whcih have been changed to <OBJECT> tag so as to support HTML5 in future:
    +<OBJECT type=" application/x-java-applet"+
    style    = "position:absolute;border:0px;left:184;top:95;height:180;width:364;"
    name     = "TreeView"
    id       = "TreeView"
    hspace   = "0"
    vspace   = "0"
    align    = "top"
    +>+
    +<PARAM name="code" value=”jtreeviewapplet.JTreeViewAppletMain.class”>+
    +<PARAM name="codebase" value="/Project/HTML/ABC/">+
    +<PARAM name="archive" value=" XYZ.jar">+
    +<PARAM name="archive" value=" ABC.jar">+
    +<PARAM name="scriptable" value="true">+
    +<PARAM NAME="onSelected" VALUE="onSelect_Handler">+
    +<PARAM NAME="onFinishNormalize" VALUE="onFinishNormalize_Handler">+
    +</OBJECT>+
    After changing the *<applet>* tag to *<object>* tag , my applet itself is not loading and it gives class not found exception for jtreeviewapplet.JTreeViewAppletMain.class.
    (Note: For both working and not working condition, I am using latest JDK 1.7 update 9 for compiling the code and in my system I am having latest JRE1.7 update 9 to run the applet code. I am using InternetExplorer 8 and InternetExplorer 9 browser)
    Can anybody help me to find out where I am going wrong?
    Edited by: 975931 on Dec 12, 2012 1:24 AM

    You might want to stick to the documentation:
    http://docs.oracle.com/javase/tutorial/deployment/index.html
    and use the deployment toolkit.
    PS: use \ tags when posting anything code related. That makes it readable and it keeps the forum from trying to interpret it.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • How to display applet not supported message?

    I would like the HTML page with applet to display some useful information when the browser does not support applet. I use the following format, however it does not show the word, can anybody help me?
    <applet
    codebase = ""
    archive = "applets.jar"
    code = "DemoSwitchApplet.class"
    name = "Demo Switch"
    width = "400"
    height = "300"
    hspace = "0"
    vspace = "0"
    align = "top"
    >
    <NOTSupported>
              You need JRE 1.3.1 to run this applet,
              <br>Please download the required software and install.
              <br>Click<a href = "http://java.sun.com/products/archive/j2se/1.3.1/jre/index.html">here</a>
              to download it from Sun website.
    </NotSupported>
    </applet>

    ?

  • [Needing Help] J2EE proyect with Applet client

    Hello, I'm Maximiliano and I'm working in a proyect in J2EE.
    I'm using netbeans for developing.
    I'm trying to include a applet in my netbeans proyect but the netbeans IDE compile/save the classes in WAR/WEB-INF/classes and that folder it's not public, so i can't call my applet from my index.jsp.
    If i move the class file to the root of the WAR it works but the imports for mi ejbs are broken.(Because they're in /WEB-INF/lib)
    I've also tried to create a separate proyect for the applet and packaging all in a EAR package (with a simple ejb too) and it's not working either.
    What i need is if anyone can tell me how to call my packaged applet from my index.jsp
    I know including applets in html with <applet> tag but i cannot resolve the correct path to my applet, or if i have to modify my proyect.
    Thanks, Maximiliano.
    And example will be much apreciated.

    its a very good question actually - I have no idea how to achieve that. My gut feeling says that you certainly want to turn the applet into a separate project, as the applet is basically a client to your JEE environment and not part of the JEE application itself. Turning it into a separate war module seems like the thing to do - perhaps even put it outside your application EAR.
    The imports of the EJBs are not going to work in any case, even if you manage to get them on the applet's classpath. Your applet is not running on the server, thus it could only call EJB methods through the remote interface, for which you need a a set of libraries from the server and you somehow need to get the remote interface classes on the classpath of your applet - quite difficult to setup.
    If you want to invoke EJB methods from the applet, I would really suggest turning them into jax-ws webservices as that makes it such that you don't need any additional libraries to be able to do it. The Java 6 runtime already has jax-ws 2.x inside it, and it is dead easy to call a webservice from a client application.

  • Can't create dynamic html elements with jsp????? important

    Hi All,
    I am having problem creating dynamic html elements with jsp tags, i have tried to use EL and java scriplet, both of them don't work.
    i am trying to create dynamic menu in my "rightMenu.jspf", based on, if user has logged in or not.
    some like this!
    <jsp:if test ="${validUser == null}">
    some simple text menu here
    </jsp:if>
    but it is not working. it simply loading all and images with in statement, regardless of whether user has logged in or not. i think some how if statement is not working properly.
    "validUser" is a session bean, which is not creating at this point, it will created when user will log in successfully. and also this session bean does not exist at the page, where i am trying to check that .
    Is there any way to create dynamic values in jsp. It is really important, is there any body who help me in this matter. i would be really grateful.
    zaman

    hi jaspre,
    thanks for replying me. you know what, is it not something wrong with web.xml file. i remember once, i deleted some from there, a property with "*.jsp". i can't remember what exactly was it though.
    all if statements works on files ending with extension ".jsp" but don't work only on with extension ".jspf". there must be to do with this.
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
    <servlet>
    <servlet-name>ValidateServlet</servlet-name>
    <servlet-class>ValidateServlet</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>ValidateServlet</servlet-name>
    <url-pattern>/ValidateServlet</url-pattern>
    </servlet-mapping>
    <servlet>
    <servlet-name>dwr-invoker</servlet-name>
    <servlet-class>org.directwebremoting.servlet.DwrServlet</servlet-class>
    <init-param>
    <param-name>debug</param-name>
    <param-value>true</param-value>
    </init-param>
    <init-param>
    <param-name>pollAndCometEnabled</param-name>
    <param-value>true</param-value>
    </init-param>
    </servlet>
    <servlet-mapping>
    <servlet-name>dwr-invoker</servlet-name>
    <url-pattern>/dwr/*</url-pattern>
    </servlet-mapping>
    <session-config>
    <session-timeout>
    30
    </session-timeout>
    </session-config>
    <welcome-file-list>
         <welcome-file>
    main.jsp
    </welcome-file>
    </welcome-file-list>
    </web-app>
    if any one can figure it out. i would be grateful.
    zaman

  • Get JSP file to run with an applet tag under JDeveloper

    I Created an applet and an html file under JDeveloper. with the applet tag in the html file.
    when I run the html file the applet runs perfectly.
    I Created a jsp file in the same project with the applet and the html file under JDeveloper. I copied and pasted the applet tag from the html file to the jsp file.
    When I try to run the jsp file under JDeveloper I get
    java.io.FileNotFoundExceptions for all of the jar files in the Applet tag ARCHIVE and for the applet tag CODE
    This is the applet tag that I copied and pasted from the html file to the jsp file
    BEGIN:
    <APPLET CODE="myapplet.Applet1" ARCHIVE="jdev-rt.jar,ojsp.jar,ojsputil.jar,oc4j.jar,servlet.jar,ojc.jar" HEIGHT="200" WIDTH="200" ALIGN="bottom">This browser does not appear to support Applets.</APPLET>
    END:
    Here three example of the exceptions that I got BEGIN:
    1.
    java.io.FileNotFoundException: http://139.169.225.224:8988/JspToAppletWS-JspAppletInstantiation-context-root/jdev-rt.jar
    2.
    java.io.FileNotFoundException: http://139.169.225.224:8988/JspToAppletWS-JspAppletInstantiation-context-root/jdev-rt.jar
    3.
    java.lang.ClassNotFoundException: myapplet.Applet1
    Here three example of the exceptions that I got END:
    This is the html file that works BEGIN:
    <HTML>
    <HEAD>
    <TITLE>
    Title
    </TITLE>
    </HEAD>
    <BODY>
    <H2>
    This is sample HTML text.
    </H2>
    <BR>
    <APPLET CODE="myapplet.Applet1" ARCHIVE="jdev-rt.jar,ojsp.jar,ojsputil.jar,oc4j.jar,servlet.jar,ojc.jar" HEIGHT="200" WIDTH="200" ALIGN="bottom">This browser does not appear to support Applets.</APPLET>
    </BODY>
    </HTML>
    This is the html file that works END:
    This is the JSP file that does not work BEGIN:
    <!--%@ page contentType="text/html;charset=windows-1252"%-->
    <%@ page import = "myapplet.Applet1, java.util.Enumeration, java.util.Vector, javax.swing.JFrame, java.lang.*" contentType="text/html;charset=windows-1252"%>
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
    <title>
    Hello World
    </title>
    </head>
    <body>
    <h2>
    The current time is:
    </h2>
    <p>
    <%= new java.util.Date() %></p>
    <APPLET CODE="myapplet.Applet1" ARCHIVE="jdev-rt.jar,ojsp.jar,ojsputil.jar,oc4j.jar,servlet.jar,ojc.jar" HEIGHT="200" WIDTH="200" ALIGN="bottom">This browser does not appear to support Applets.</APPLET-->
    </body>
    </html>
    This is the JSP file that does not work END:
    I would like to know what I need to do so that I can run
    the Jsp file under JDeveloper with the applet tag without any exceptions.

    Hi,
    I meet the same problem and can not get a solution from this forum or other forum in internet, either.
    Have you already solved this problem? Can you tell me your solution? thanks in advance.
    Regards

  • JDK 1.4.2_10; problem with applet/classpath/OBJECT tag

    I'm supporting an applet that needs to run in JDK 1.4.2_10 in order to work. (I don't own the code, so I can't fix the issue)
    I'd like to force that particular applet to run under JDK 1.4.2_10, but allow other applets to run on the current default JVM.
    I'm trying to do this by using the JDK's htmlconverter.exe utility to force the use of JDK 1.4.2_10. That part is working as expected, but I'm experiencing a side effect.
    The problem is that, when I use the OBJECT tag instead of the APPLET tag, the browser attempts to download the class with this URL
    http://hostname.here.com/app.testing/app.testbed/classes/appls%2fDOLARS%2fuser%2fApplet%2fclass.class
    instead of this URL
    http://hostname.here.com/app.testing/app.testbed/classes/appls/DOLARS/user/Applet.class
    The second URL works; the first does not. When I use the APPLET tag, it generates the second URL and downloads the class successfully.
    I'd like to a) use the OBJECT tag. b) get it to use the correct URL to download the Applet.class file. What do I need to do to make this happen?
    Thanks,
    Tom Valesky

    Here's the exception I'm getting (slightly sanitized):
    Java Plug-in 1.4.2_10
    Using JRE version 1.4.2_10 Java HotSpot(TM) Client VM
    User home directory = C:\Documents and Settings\tvalesky
    c: clear console window
    f: finalize objects on finalization queue
    g: garbage collect
    h: display this help message
    l: dump classloader list
    m: print memory usage
    o: trigger logging
    q: hide console
    r: reload policy configuration
    s: dump system and deployment properties
    t: dump thread list
    v: dump thread stack
    x: clear classloader cache
    0-5: set trace level to
    load: class appls/DOLARS/user/Applet.class not found.
    java.lang.ClassNotFoundException: appls.DOLARS.user.Applet.class
         at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source)
         at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
         at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
         at java.lang.Thread.run(Unknown Source)
    Caused by: java.io.IOException: open HTTP connection failed:http://hostname.com/DOLARS.testing/dolars.testbed/classes/appls%2fDOLARS%2fuser%2fApplet%2fclass.class
         at sun.plugin2.applet.Applet2ClassLoader.getBytes(Unknown Source)
         at sun.plugin2.applet.Applet2ClassLoader.access$000(Unknown Source)
         at sun.plugin2.applet.Applet2ClassLoader$1.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         ... 7 more
    Exception: java.lang.ClassNotFoundException: appls.DOLARS.user.Applet.class

  • ER: HTML Applet tag syntax warning - or HTML syntax checker for JDEV.

    Hi,
    I just spent ages (an hour or two) debugging an applet and it turned out that I had left a comma "," out of my 'archive=..' parameter of the 'applet' tag in the HTML :-(.
    E.g. I had <applet code="x" archive="a.jar b.jar, c.jar, d.jar"> and IE simply didn't load 'b.jar' so I got the usual 'class not found' exception. After signing every jar and putting every jar in every directory I finally noticed the commas between some of the jars.
    I can understand IE not helping me load an Applet since, from MS's point of view, that is evil Java code, but JDev must know the syntax of a HTML applet tag too so it could highlight the error for me.
    Alternatively does anyone know of a HTML checker plugin for JDEV?
    Regards,
    Simon.

    No comments?
    I've been looking around for a HTML syntax checker and there are plenty around - just google "html validation". None so far have picked up the missing comma in my busted applet tag. I guess with a missing comma it just looks like a file name with a space in it anyway.
    I still think JDeveloper could flag semantic errors like this at development time.
    Cheers,
    Simon.

  • Run applet with object tag

    Hi people.
    I need your assistance in my problem.
    I try to run the simple applet (from Java Tutorial Documents):
    import java.applet.Applet;
    import java.awt.Graphics;
    public class HelloApplet extends Applet {
    public void paint(Graphics g) {
    g.drawString("Hello Applet!!", 10, 10);
    with a help of two different HTMLs.
    First with an <APPLET> tag:
    <HTML>
    <BODY>
    <APPLET CODE="dir1.class" WIDTH=150 HEIGHT=25>
    </APPLET>
    </BODY>
    </HTML>
    Second with an <OBJECT> tag:
    <HTML>
    <BODY>
    <OBJECT classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93"
         codebase="http://javaweb.eng/plugin/jre-1_2_2-win.exe#Version=1,2,0,0"
         align="left" border="0" width="100%" height="100%">
    <param name="code" value="dir2.class">
    <param name="codebase" value="./">
    <param name="type" value="application/x-java-applet;version=1.2">
    </OBJECT>
    </BODY>
    </HTML>
    The problem is that in case of <APPLET> tag everything is OK.
    In case of <OBJECT> tag the applet don�t run.
    And that is only on my machine.
    On the others everything is OK in both cases.
    HELP!!!
    My machine properties:
         Win95
         IE5.5
    PlugIN: jre1_2_2-win.exe

    Hmmm... I've already seen the Java Plugin going mad if you make too much experimentations with it.
    My advice : uninstall it properly and make it be reinstalled by the automatic plugin installation of IE (just by loading the HTML page with the <OBJECT> tag).
    I hope it will work...
    Matthieu

  • Applet doesn't work with object tags--PLZ HELP!

    <NOEMBED>
    </NOEMBED>
    </EMBED>
    </COMMENT>
    </OBJECT>

    ooops! The applet is not displayed with object tags generated by HtmlConverter utility, The applet is supposed to display a JTable and connect to Oracle DB using JDBC. The web server is Tomcat 4.1.29
    <OBJECT
        classid = "clsid:CAFEEFAC-0014-0001-0002-BBCDEFFEDCBA"
        codebase = "http://java.sun.com/products/plugin/autodl/jinstall-1_4_1_02a-windows-i586.cab#Version=1,4,1,21"
        WIDTH = 800 HEIGHT = 500 NAME = "Edit Trunks" >
        <PARAM NAME = CODE VALUE = "cbhtolApplet.class" >
        <PARAM NAME = ARCHIVE VALUE = "trnkapplet.jar,ojdbc14.jar" >
        <PARAM NAME = NAME VALUE = "Edit Trunks" >
        <PARAM NAME = "type" VALUE = "application/x-java-applet;jpi-version=1.4.1_02a">
        <PARAM NAME = "scriptable" VALUE = "false">
        <COMMENT>
            <EMBED
                type = "application/x-java-applet;jpi-version=1.4.1_02a"
                CODE = "cbhtolApplet.class"
                ARCHIVE = "trnkapplet.jar,ojdbc14.jar"
                NAME = "Edit Trunks"
                WIDTH = 800
                HEIGHT = 500
                scriptable = false
               pluginspage = "http://java.sun.com/products/plugin/index.html#download">
                <NOEMBED>
                </NOEMBED>
            </EMBED>
        </COMMENT>
    </OBJECT>Appreciate your help!

Maybe you are looking for

  • Different background for each space?

    Is it possible to have a different background for each virtual desktop space?

  • NullPointerException at EJB-Relationship

    Hi: I'm trying to create a relationship between to CMP 2.0 entites using JDeveloper. It's a unidirectional One-to-Many relation between Car-producer and Car-typs. The car-type-bean has the producer number as a foreign key. I have generated the EJB'S

  • How to re-kerberize when node is not 127.0.0.1

    I'm re-kerberizing 10.6.2 server per Apple's instructions <http://support.apple.com/kb/HT3655>. But my current OD info is at LDAPv3/192.168.1.200 instead of 127.0.0.1. Thus, when I run the slapconfig -kerberize command it fails with sso_util status 2

  • Msi gx60 destroyer problems

    hey just bought myself a new gaming  notebook from msi and ever every seemed to be working fine when i first got but now a couple of days later the dragon gaming center wont open and when i try to open it, it says "dragon gaming center is only for ms

  • "When Firefox starts:" is set to "Show my homepage", but it still shows the last page visited anyway.

    Firefox 20, Ubuntu 12.04, Cinnamon desktop. "When Firefox starts" is set to "Show my homepage". I tried settting browser.sessionstore.max_resumed_crashes to zero. Still does it. I think it happens mosts often if I log out without closing Firefox firs