Help!!! Need Java Applet to work in IE

I found some applets (text scrollers) from the sun site that i wanted to use. downloaded them, but they do not work in IE that does not have JVM. in IE that does have JVM it says 'Java 1.1 Required' where the applet should be. is there a simple way to get sun java applets to work with IE and the MS Virtual Machine? I can't require my site visitors to have to download extra toys/plugins...

If you are looking for a purely AWT scrolling applet. Here is one I wrote several years ago. Please note that there are some deprecated methods in it (mainly the thread start and stop methods). It will still compile though. If you want it, take it.
Source:import java.awt.*;
import java.awt.event.*;
import java.applet.*;
import java.net.*;
public class ScrollApplet extends Applet implements Runnable
   /*=*********************
   * private data members *
   private Thread myThread = null;
   private boolean hasTextDisplayed;
   private int appletWidth, appletHeight;
   private int yPosition;
   private int xPosition;
   private Image textImage;
   private int imageWidth;
   private Graphics textGraphics;
   private Cursor oldCursor;
   private Cursor newCursor = new Cursor(Cursor.HAND_CURSOR);
   //parameters
   private int delay;
   private String displayText;
   private Color bgColor, fgColor;
   private int fontSize, fontStyle;
   private Font fontType;
   private String urlValue;
   /*=***************
   * applet methods *
   public void init()
      //assign values to private data members
      hasTextDisplayed = false;
      appletHeight = yPosition = getSize().height;
      appletWidth = xPosition = getSize().width;
      //set up the environment
      extractParameters();
      //determine the yPosition to place the image
      calculateYPosition();
      //set up the text image
      FontMetrics fm = getFontMetrics(fontType);
      imageWidth = fm.stringWidth(displayText);
      textImage = createImage(imageWidth, appletHeight);
      textGraphics = textImage.getGraphics();
      textGraphics.setColor(bgColor);
      textGraphics.fillRect(0,0,imageWidth,appletHeight);
      textGraphics.setColor(fgColor);
      textGraphics.setFont(fontType);
      textGraphics.drawString(displayText, 0, yPosition);
      oldCursor = this.getCursor();
      addMouseListener(new MouseAdapter() {
         public void mouseExited(MouseEvent e)
            if (urlValue != null) {
               Component thisApplet = e.getComponent();
               thisApplet.setCursor(oldCursor);
            showStatus(" ");
            myThread.resume();
         public void mouseEntered(MouseEvent e)
            myThread.suspend();
            if (urlValue != null) {
               Component thisApplet = e.getComponent();
               thisApplet.setCursor(newCursor);
               showStatus(urlValue);
            else
               showStatus("paused");
         public void mouseClicked(MouseEvent e)
            if (urlValue != null)
               try {
                  URL u = new URL(urlValue);
                  getAppletContext().showDocument(u, "_self");
               } catch(MalformedURLException ex) {
               showStatus("MalformedURLException: " +ex);
   }//end init method
   public void start()
      myThread = new Thread(this);
      myThread.start();
   }//end start method
   public void update(Graphics g)
   //overwrote this method to avoid repainting of background before all text displays
      if (hasTextDisplayed == true)
         //repaint the background
         g.setColor(bgColor);
         g.fillRect(xPosition+imageWidth, 0, appletWidth - (xPosition + imageWidth),
                      appletHeight);
         g.setColor(fgColor);
      paint(g);
   }//end update method
   public void paint(Graphics g)
      setBackground(bgColor);
      g.drawImage(textImage,xPosition,0,this);
   }//end paint method
   public void stop()
   { myThread = null; }
   /*=*******************************************************************************
   * applet method getParameterInfo():                                              *
   * Returns information about the parameters that are understood by this applet.   *
   * An applet should override this method to return an array of Strings describing *
   * these parameters.  Each element of the array should be a set of three Strings  *
   * containing the name, the type, and a description.                              *
   public String[][] getParameterInfo()
      String parameterInfo[][] = {
         {"DELAYPARAM", "int", "The interval to pause in milliseconds"},
         {"TEXTPARAM", "string", "The text that will be displayed"},
         {"BGPARAM", "Color", "The bg color for the applet, in html format #FFFFFF"},
         {"FGPARAM", "Color", "The fg color for the text, in html format #FFFFFF"},
         {"FONTSIZEPARAM", "int", "The font size of the text"},
         {"FONTTYPEPARAM", "string", "The name of the font to use"},
         {"FONTSTYLEPARAM", "string", "bold, italic, or bold+italic"},
         {"URLPARAM", "string", "hyperlink"}
      return parameterInfo;
   }//end getParameterInfo method
   /*=*****************************************************************************
   * applet method getAppletInfo():                                               *
   * Returns information about this applet. An applet should override this method *
   * to return a String containing information about the author, version, and     *
   * copyright of the applet.                                                     *
   public String getAppletInfo()
      String infoAboutMe;
      infoAboutMe = new String(
         "Author:  Your Name Here/n" +
         "Description:  My first text scroller\n" +
         "Version: 1.0"
      return infoAboutMe;
   }//end getAppletInfo method
   /*=***************
   * thread methods *
   public void run()
      Thread current = Thread.currentThread();
      //loop until thread is stopped
      while (myThread == current)
         repaint();
         try {
            current.sleep(delay);
            xPosition--;
         } catch (InterruptedException e) {}
         if (xPosition <= (appletWidth - imageWidth))
            hasTextDisplayed = true;
         else
            hasTextDisplayed = false;
         if (xPosition == (0 - imageWidth))
            xPosition = appletWidth;
   }//end required run method
   /*=**********************************************************************
   * extractParameters():  Sets all parameter values, if any were provided *
   public void extractParameters()
      String delayValue = getParameter("DELAYPARAM");
      String textValue = getParameter("TEXTPARAM");
      String bgColorValue = getParameter("BGPARAM");
      String fgColorValue = getParameter("FGPARAM");
      String fontSizeValue = getParameter("FONTSIZEPARAM");
      String fontTypeValue = getParameter("FONTTYPEPARAM");
      String fontStyleValue = getParameter("FONTSTYLEPARAM");
      String urlParam = getParameter("URLPARAM");
      //set delay to one tenth of a second if missing parameter
      delay = ((delayValue == null) ? 100 : Integer.parseInt(delayValue));
      urlValue = (urlParam == null ? null : urlParam);
      displayText = ((textValue == null) ?
            new String("NO TEXT WAS PROVIDED!") :
            textValue);
      bgColor = determineColor(bgColorValue);
      fgColor = determineColor(fgColorValue);
      fontStyle = determineFontStyle(fontStyleValue);
      fontSize = ((fontSizeValue == null) ? 12 : Integer.parseInt(fontSizeValue));
      fontType = new Font(fontTypeValue, fontStyle, fontSize);
   }//end extractParameters method
   /*=*************************************************
   * determineColor():  returns the appropriate color *
   public Color determineColor(String value)
      return parseHTMLHex(value);
   }//end determineColor method
   /*=*****************************************************************************
   * parseHTMLHex(): parses an HTML hex (eg #FFFFFF) and returns the Color object *
   public static Color parseHTMLHex(String htmlHex) {
      Color color = new Color(220,220,220);  //default grey
      if (htmlHex != null) {
         String red = htmlHex.substring(1,3);
         String green = htmlHex.substring(3,5);
         String blue = htmlHex.substring(5);
         color = new Color(Integer.parseInt(red,16),
                       Integer.parseInt(green,16),
                       Integer.parseInt(blue,16));
      }//end if
      return color;
   }//end parseHTMLHex method
   /*=******************************************
   * determineFontStyle():  returns font sytle *
   public int determineFontStyle(String value)
      int returnVal;
      if (value == null)
         returnVal = Font.PLAIN;
      else if (value.equalsIgnoreCase("plain"))
         returnVal = Font.PLAIN;
      else if (value.equalsIgnoreCase("bold"))
         returnVal = Font.BOLD;
      else if (value.equalsIgnoreCase("italic"))
         returnVal = Font.ITALIC;
      else if (value.equalsIgnoreCase("bold+italic"))
         returnVal = Font.BOLD + Font.ITALIC;
      else
         returnVal = Font.PLAIN;
      return returnVal;
   }//end determineFontStyle method
   /*=**********************************************************
   * calculateYPosition(): want text to be in middle of applet *
   public void calculateYPosition()
      //wasYPositionCalculated = true;
      //make calculations to center font in applet window
      int appletMidHeight = appletHeight / 2;         //the middle of the applet
      FontMetrics fm = getFontMetrics(fontType);    //font metrics for current font
      int fontMidHeight = fm.getAscent() / 2;         //the middle of the font
      int currentFontSizeValue;                       //temp value for font size
      //if the font size if too big, fix it
      if ((currentFontSizeValue = fm.getAscent()) > appletHeight)
         //cycle through font sizes until find one that fits
         while (currentFontSizeValue > appletHeight)
            fontType = new Font(getParameter("FONTTYPEPARAM"), fontStyle, --fontSize);
            fm = getFontMetrics(fontType);
            currentFontSizeValue = fm.getAscent();
         //set the new values for the new font
         setFont(fontType);
         fm = getFontMetrics(fontType);
         fontMidHeight = fm.getAscent() / 2;
      yPosition = appletMidHeight + fontMidHeight - 3;
   }//end calculateYPosition()
}//end applethtml:<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=windows-1252">
<TITLE>Test scroller applet</title>
</head>
<BODY>
<h1>Scroller Applet</h1>
<!--CODEBASE = "."-->
<APPLET
  CODE     = "ScrollApplet.class"
  NAME     = "TestApplet"
  WIDTH    = 400
  HEIGHT   = 30
  HSPACE   = 0
  VSPACE   = 0
  ALIGN    = middle
>
<PARAM NAME="DELAYPARAM" VALUE="10">
<PARAM NAME="TEXTPARAM" VALUE="Simple Old Scrolling Applet?">
<PARAM NAME="BGPARAM" VALUE="#000000">
<PARAM NAME="FGPARAM" VALUE="#CCCCCC">
<PARAM NAME="FONTSIZEPARAM" VALUE="24">
<PARAM NAME="FONTTYPEPARAM" VALUE="TimesRoman">
<PARAM NAME="FONTSTYLEPARAM" VALUE="italic">
<PARAM NAME="URLPARAM" VALUE="http://quote.yahoo.com/quotes?SYMBOLS=DISH">
</applet>
</body>
</html>tajenkins

Similar Messages

  • I am trying to use an education program that needs Java applets to install and use and it will not use Safari. When I download IE from the web it will not install. How can I get a browser that will work on my MacAir for travel use of this program?

    I am trying to use and education program that needs Java applets and it will not run on Safari. IE will not install from the web. How do I get a browser that will work to install so I can use this program when I travel.

    Try using FireFox. IE will only run on a Mac if you run Windows on the Mac.
    Windows on Intel Macs
    There are presently several alternatives for running Windows on Intel Macs.
    Install the Apple Boot Camp software.  Purchase Windows 7 or Windows 8.  Follow instructions in the Boot Camp documentation on installation of Boot Camp, creating Driver CD, and installing Windows.  Boot Camp enables you to boot the computer into OS X or Windows.
    Parallels Desktop for Mac and Windows XP, Vista Business, Vista Ultimate, or Windows 7.  Parallels is software virtualization that enables running Windows concurrently with OS X.
    VM Fusion and Windows XP, Vista Business, Vista Ultimate, or Windows 7.  VM Fusion is software virtualization that enables running Windows concurrently with OS X.
    CrossOver which enables running many Windows applications without having to install Windows.  The Windows applications can run concurrently with OS X.
    VirtualBox is a new Open Source freeware virtual machine such as VM Fusion and Parallels that was developed by Solaris.  It is not as fully developed for the Mac as Parallels and VM Fusion.
    Note that Parallels and VM Fusion can also run other operating systems such as Linux, Unix, OS/2, Solaris, etc.  There are performance differences between dual-boot systems and virtualization.  The latter tend to be a little slower (not much) and do not provide the video performance of the dual-boot system. See MacTech.com's Virtualization Benchmarking for comparisons of Boot Camp, Parallels, and VM Fusion. A more recent comparison of Parallels, VM Fusion, and Virtual Box is found at Virtualization Benchmarks- Parallels 10 vs. Fusion 7 vs. VirtualBox. Boot Camp is only available with Leopard and later. Except for Crossover and a couple of similar alternatives like DarWine you must have a valid installer disc for Windows.
    You must also have an internal optical drive for installing Windows. Windows cannot be installed from an external optical drive.

  • Java applets that worked fine under 10.6 don't work under 10.7. What can I do to correct this?

    Java applets that worked just fine are no longer working after upgrading to MacOS X 10.7 (Lion).  Here is one example: 
    So far, I've found two Java Applets that have become inoperative under 10.7.  Here's one example: http://www.vimas.com/videoLarge.php
    I did download and install the Java  VM for Lion and I did "activate" the applet when prompted to do so.  However, the example  cited above fails to load.
    A second example is  JFileUpload which enables a drag & drop UI with which to upload files.  Worked great under 10.6 but under 10.7 dropping a file on the UI only causes the web browser to display the file, not upload it.

    @etresoft: "You have old cache files left over from you Snow Leopard Java installation. Just run the Jave Preferences application and delete your cache files."
    I did that right off but this is not the issue and that tactic didn't work.  Apple has acknowledged the issue and the workaround (extract the applet from the web page) seems to suggest that Safari is at fault.  Safari 5.2 was just released today but, unfortunately, doesn't correct this issue.
    In the case of the applet that I use most often (JFileUpload), it also has a File menu so I use that instead.  Nonetheless, I sure do miss drag & drop.  As more and more of our Mac users upgrade to Lion and bump into this issue, we expect our  support effort to be challenged with an increasing number of irate users.  It doesn't help to be able to say "It's Apple's Fault" but that's all we can say.

  • Java Applets cannot work in IE when PAC file is in shared folder

    I have a PAC file (proxy auto config) residing in a shared folder, i.e. \\fileserver\share\proxy.pac. My IE and firefox is configured to point to the PAC file. Java applet is working fine in Firefox but fails to run in IE.
    From the Java console, the applet seems to be trying to access the internet via DIRECT connection. The applet works properly when I configured IE to point to a PAC file in a web server, ie http://webserver/proxy.pac or in the local drive, ie file://c:\proxy.pac. My objective is to configure IE to point to a PAC file in a shared folder and make it work. Can anyone help?
    Below are the logs from both IE and Firefox Java Console (thrimed):
    1) IE:
    Java Plug-in 1.6.0_13
    Using JRE version 1.6.0_13 Java HotSpot(TM) Client VM
    User home directory = C:\Documents and Settings\xxx
    network: No certificate info for unsigned JAR file: https://internet-banking.dbs.com.sg/IB/Login2.jar
    network: Cache entry found [url: https://internet-banking.dbs.com.sg/IB/Login2.jar, version: null]
    network: Connecting https://internet-banking.dbs.com.sg/IB/Login2.jar with proxy=DIRECT
    network: CleanupThread used 299461 us
    network: Connecting http://internet-banking.dbs.com.sg:443/ with proxy=DIRECT
    network: Connecting https://internet-banking.dbs.com.sg/IB/Login2.jar with proxy=DIRECT
    network: Connecting http://internet-banking.dbs.com.sg:443/ with proxy=DIRECT
    java.net.ConnectException: Connection timed out: connect
         at java.net.PlainSocketImpl.socketConnect(Native Method)
         at java.net.PlainSocketImpl.doConnect(Unknown Source)
         at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
         at java.net.PlainSocketImpl.connect(Unknown Source)
         at java.net.SocksSocketImpl.connect(Unknown Source)
         at java.net.Socket.connect(Unknown Source)
         at com.sun.net.ssl.internal.ssl.SSLSocketImpl.connect(Unknown Source)
         at sun.net.NetworkClient.doConnect(Unknown Source)
         at sun.net.www.http.HttpClient.openServer(Unknown Source)
         at sun.net.www.http.HttpClient.openServer(Unknown Source)
         at sun.net.www.protocol.https.HttpsClient.<init>(Unknown Source)
         at sun.net.www.protocol.https.HttpsClient.New(Unknown Source)
         at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.getNewHttpClient(Unknown Source)
         at sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source)
         at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source)
         at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
         at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(Unknown Source)
         at sun.plugin.PluginURLJarFileCallBack.downloadJAR(Unknown Source)
         at sun.plugin.PluginURLJarFileCallBack.access$000(Unknown Source)
         at sun.plugin.PluginURLJarFileCallBack$2.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)
         at sun.net.www.protocol.jar.JarFileFactory.get(Unknown Source)
         at sun.net.www.protocol.jar.JarURLConnection.connect(Unknown Source)
         at sun.plugin.net.protocol.jar.CachedJarURLConnection.connect(Unknown Source)
         at sun.plugin.net.protocol.jar.CachedJarURLConnection.getJarFileInternal(Unknown Source)
         at sun.plugin.net.protocol.jar.CachedJarURLConnection.getJarFile(Unknown Source)
         at sun.misc.URLClassPath$JarLoader.getJarFile(Unknown Source)
         at sun.misc.URLClassPath$JarLoader.access$600(Unknown Source)
         at sun.misc.URLClassPath$JarLoader$1.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         at sun.misc.URLClassPath$JarLoader.ensureOpen(Unknown Source)
         at sun.misc.URLClassPath$JarLoader.<init>(Unknown Source)
         at sun.misc.URLClassPath$3.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         at sun.misc.URLClassPath.getLoader(Unknown Source)
         at sun.misc.URLClassPath.getLoader(Unknown Source)
         at sun.misc.URLClassPath.getResource(Unknown Source)
         at sun.plugin2.applet.Plugin2ClassLoader$2.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         at sun.plugin2.applet.Plugin2ClassLoader.findClassHelper(Unknown Source)
         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)
    network: Connecting https://internet-banking.dbs.com.sg/IB/Login2.jar with proxy=DIRECT
    network: Connecting http://internet-banking.dbs.com.sg:443/ with proxy=DIRECT
    2) Firefox:
    Java Plug-in 1.6.0_13
    Using JRE version 1.6.0_13 Java HotSpot(TM) Client VM
    User home directory = C:\Documents and Settings\xxx
    network: No certificate info for unsigned JAR file: https://internet-banking.dbs.com.sg/IB/Login2.jar
    network: Cache entry found [url: https://internet-banking.dbs.com.sg/IB/Login2.jar, version: null]
    network: Connecting https://internet-banking.dbs.com.sg/IB/Login2.jar with proxy=HTTP @ mocwsg01.m1.com.sg/10.33.90.91:8080
    network: CleanupThread used 306588 us
    security: Loading Root CA certificates from C:\Program Files\Java\jre6\lib\security\cacerts
    security: Loaded Root CA certificates from C:\Program Files\Java\jre6\lib\security\cacerts
    security: Loading SSL Root CA certificates from C:\Program Files\Java\jre6\lib\security\cacerts
    security: Loaded SSL Root CA certificates from C:\Program Files\Java\jre6\lib\security\cacerts
    security: Loading Deployment SSL certificates from C:\Documents and Settings\xxx\Application Data\Sun\Java\Deployment\security\trusted.jssecerts
    security: Loaded Deployment SSL certificates from C:\Documents and Settings\xxx\Application Data\Sun\Java\Deployment\security\trusted.jssecerts
    security: Loading certificates from Deployment session certificate store
    security: Loaded certificates from Deployment session certificate store
    security: Checking if certificate is in Deployment denied certificate store
    network: ResponseCode for https://internet-banking.dbs.com.sg/IB/Login2.jar : 200
    network: Encoding for https://internet-banking.dbs.com.sg/IB/Login2.jar : null
    network: Disconnect connection to https://internet-banking.dbs.com.sg/IB/Login2.jar
    basic: Applet loaded.
    basic: Applet resized and added to parent container
    basic: PERF: AppletExecutionRunnable - applet.init() BEGIN ; jvmLaunch dt 1677884 us, pluginInit dt 1844261 us, TotalTime: 3522145 us
    basic: Applet initialized
    basic: Removed progress listener: sun.plugin.util.GrayBoxPainter$GrayBoxProgressListener@15ee671
    basic: Applet made visible
    basic: Starting applet
    basic: Applet started
    basic: Told clients applet is started

    Did you ever resolve this issue ? We have recently moved from a http based pac file to using file://netlogon share/proxy.pac. Recievng similar errors as you describe with various applets. Seems to work ok when using the same pac file launched by http rather than file. Seems to be various BUG's marginally related to similar issues but nothing to confirm that its a real problem.
    Be great if anyone has an answer to this.
    Thanks

  • Java applet not working savevid keepvid

    Hi all,
    I'm sure I'm not the only one who has been confounded by Java applets not working in certain download web services; in my case, keepvid.com and savevid.com to download copies of youtube videos.  It has been a huge headache and even debilitating in my case.  I teach film and video to middle schoolers, and we often use youtube as a resource for our class projects. 
    I found a solution today, I think, and wanted to share it:
    I installed the browser called "Torch" and it seems to work fine, so far.

    thanx 4 replying
    using the browser to view Applet is not recomended that is because if u change the the source-code and recompile the applet then run it using the broswer it will run the old-version
    Also i've found the solution here
    http://www.cs.utah.edu/classes/cs1021/notes/lecture03/eclipse_help.html

  • Need help getting my applets to work on web pages!

    I've been trying to get it to work for a while now, and I no idea why it won't work! I've tried all kinds of things to get it to work, but it still won't work. All I want to do is make a simple applet, don't care what it does, and put it on a web page.
    Here is my HTML code:
    <applet code=?Slime2P.class? height=?300? width=?400? codebase=?http://www.spinarcade.com/tests?>
    </APPLET>
    Here is a link to what happens:
    [http://www.spinarcade.com/tests/duk.html|http://www.spinarcade.com/tests/duk.html]
    Here is the errors:
    load: class ?Slime2P.class? not found.
    java.lang.ClassNotFoundException: ?Slime2P.class?
         at sun.applet.AppletClassLoader.findClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at sun.applet.AppletClassLoader.loadClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at sun.applet.AppletClassLoader.loadCode(Unknown Source)
         at sun.applet.AppletPanel.createApplet(Unknown Source)
         at sun.plugin.AppletViewer.createApplet(Unknown Source)
         at sun.applet.AppletPanel.runLoader(Unknown Source)
         at sun.applet.AppletPanel.run(Unknown Source)
         at java.lang.Thread.run(Unknown Source)
    It works fine when I run the applet in eclipse, and I've tried many different applets. I tried using a cool program I wanted to put online first, then I made a simple program to try, and then I even downloaded the file from a tutorial and didn't edit it at all... nothing works!
    Here's code from one of the applets (Simple applet with green lines):
    import java.applet.*;
    import java.awt.*;
    public class Duck extends Applet {
    int width, height;
    public void init() {
    width = getSize().width;
    height = getSize().height;
    setBackground( Color.black );
    public void paint( Graphics g ) {
    g.setColor( Color.green );
    for ( int i = 0; i < 10; ++i ) {
    g.drawLine( width, height, i * width / 10, 0 );
    I have all the .class file and the html page in the same place (http://www.spinarcade.com/tests).
    Thank you for your help! It is most likely something simple...
    Edited by: Donv7 on Jul 17, 2008 2:27 PM

    Here is your html:
    <HTML>
    <HEAD>
    <TITLE>Duk!</TITLE>
    </HEAD>
    <body bgcolor="#DAE9F3">
    <center>
    <applet code=?Slime2P.class? height=?300? width=?400?>
    </APPLET>
    ducks these dayz...<br>
    codebase=?http://www.spinarcade.com/tests?<br>
    C:\Documents and Settings\Don\Desktop<br>
    http://www.spinarcade.com/tests<br>
    </center>
    </BODY>
    </HTML>Look carefully at the double quotes surrounding the red text (bgcolor).
    Look at the double quotes used in the applet tag now!!!

  • Need help with Java applet, might need NetBeans URL

    I posted the below question. It was never answered, only I was told to post to the NetBeans help forum. Yet I don't see any such forum on this site. Can someone tell me where the NetBeans help forum is located (URL).
    Here is my original question:
    I have some Java source code from a book that I want to compile. The name of the file is HashTest.java. In order to compile and run this Java program I created a project in the NetBeans IDE named javaapplication16, and I created a class named HashTest. Once the project was created, I cut and pasted the below source code into my java file that was default created for HashTest.java.
    Now I can compile and build the project with no errors, but when I try and run it, I get a dialog box that says the following below (Ignore the [...])
    [..................Dialog Box......................................]
    Hash Test class wasn't found in JavaApplication16 project
    Select the main class:
    <No main classes found>
    [..................Dialog Box......................................]
    Does anyone know what the problem is here? Why won't the project run?
    // Here is the source code: *****************************************************************************************************
    import java.applet.*;
    import java.awt.*;
    import java.awt.geom.*;
    import java.awt.event.*;
    import java.util.*;
    public class HashTest extends Applet implements ItemListener
    // public static void main(String[] args) {
    // Hashtable to add tile images
    private Hashtable imageTable;
    // a Choice of the various tile images
    private Choice selections;
    // assume tiles will have the same width and height; this represents
    // both a tile's width and height
    private int imageSize;
    // filename description of our images
    private final String[] filenames = { "cement.gif", "dirt.gif", "grass.gif",
    "pebbles.gif", "stone.gif", "water.gif" };
    // initializes the Applet
    public void init()
    int n = filenames.length;
    // create a new Hashtable with n members
    imageTable = new Hashtable(n);
    // create the Choice
    selections = new Choice();
    // create a Panel to add our choice at the bottom of the window
    Panel p = new Panel();
    p.add(selections, BorderLayout.SOUTH);
    p.setBackground(Color.RED);
    // add the Choice to the applet and register the ItemListener
    setLayout(new BorderLayout());
    add(p, BorderLayout.SOUTH);
    selections.addItemListener(this);
    // allocate memory for the images and load 'em in
    for(int i = 0; i < n; i++)
    Image img = getImage(getCodeBase(), filenames);
    while(img.getWidth(this) < 0);
    // add the image to the Hashtable and the Choice
    imageTable.put(filenames[i], img);
    selections.add(filenames[i]);
    // set the imageSize field
    if(i == 0)
    imageSize = img.getWidth(this);
    } // init
    // tiles the currently selected tile image within the Applet
    public void paint(Graphics g)
    // cast the sent Graphics context to get a usable Graphics2D object
    Graphics2D g2d = (Graphics2D)g;
    // save the Applet's width and height
    int width = getSize().width;
    int height = getSize().height;
    // create an AffineTransform to place tile images
    AffineTransform at = new AffineTransform();
    // get the currently selected tile image
    Image currImage = (Image)imageTable.get(selections.getSelectedItem());
    // tile the image throughout the Applet
    int y = 0;
    while(y < height)
    int x = 0;
    while(x < width)
    at.setToTranslation(x, y);
    // draw the image
    g2d.drawImage(currImage, at, this);
    x += imageSize;
    y += imageSize;
    } // paint
    // called when the tile image Choice is changed
    public void itemStateChanged(ItemEvent e)
    // our drop box has changed-- redraw the scene
    repaint();
    } // HashTest

    BigDaddyLoveHandles wrote:
    h1. {color:red}MULTIPOST: [http://forums.sun.com/thread.jspa?threadID=5358840&messageID=10564025]{color}
    That wasn't attention-grabbing enough apparantly. Let's try it again.
    h1. {color:red}MULTIPOST: [http://forums.sun.com/thread.jspa?threadID=5358840&messageID=10564025]{color}
    h1. {color:red}MULTIPOST: [http://forums.sun.com/thread.jspa?threadID=5358840&messageID=10564025]{color}
    h1. {color:red}MULTIPOST: [http://forums.sun.com/thread.jspa?threadID=5358840&messageID=10564025]{color}
    h1. {color:red}MULTIPOST: [http://forums.sun.com/thread.jspa?threadID=5358840&messageID=10564025]{color}
    h1. {color:red}MULTIPOST: [http://forums.sun.com/thread.jspa?threadID=5358840&messageID=10564025]{color}

  • Newbie need help wtih Java Applet noinit error

    Hi, i am having problem with a making this java applet application run, i am new to java but i am sure that my coding is right, because this what i typed from my java class book. Don't know why when i try to run it is say at the bottom of the windows explorer, "applet class name "noinit"". The code is listed below maybe someone could help me figure this out. I used NetBean to compile it, also I have the latest version of java but could not find a applet that come with the newest version of java so I'm using the j2sdk1.4.2_11 applet, and have added it to my system environment path. Maybe that could be the problem if so where do i get the newest version of the applet, because without doing what i did i could run applets in the first place. My other sample applet sample (demo's) that come with Java runs fine without any problem. Only when i run mine i get the message, "applet class name noinit".
    HTML file:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <title>Welcome Applet</title>
    </head>
    <!-- Used to load the Java .class file -->
    <applet code="WelcomeApplet.class" width="300" height="45">
    alt="Your browser understands the <;APPLET> tag but isn't running the applet, for some reason."
         Your browser is completely ignoring the <APPLET> tag!
    </applet>
    <body>
    </body>
    </html>Java code:
    /* Fig. 3.6: WelcomeApplet.java
    *  My first applet in Java
    * Created on May 2, 2006, 2:50 AM
    // Java packages
    package appletjavafig3_6;
    import java.awt.Graphics;   // import class Graphics
    import javax.swing.JApplet; // import class JApplet
    public class WelcomeApplet extends JApplet {
        public WelcomeApplet(){
        // 3rd method that is called by default
        // draw text on applets's background
        public void paint( Graphics g)
            // call superclass version of method paint
            super.paint(g);
            // draw a String at x-coordinate 25 and y coordinate 25
            g.drawString("Welcome to Java Programming!", 25,25);
        } // end method paint
    } // WelcomeApplet

    Hi,
    Your applet code in the html should be
    <applet code="appletjavafig3_6.WelcomeApplet" width="300" height="45">
    alt="Your browser understands the <;APPLET> tag but isn't running the applet, for some reason."
         Your browser is completely ignoring the <APPLET> tag!
    </applet>As the class is inside a package named appletjavafig3_6, put the class file inside a folder named appletjavafig3_6. Put the html file outside this folder and test it.

  • Need help with java applet

    Hi all,
    Am having trouble with a java applet that won't run under Mozilla, Seamonkey, and IE 6 but will run under IE 7 Beta 2. Am posting the error info below in the hope that someone can see what could be wrong as i don't want to upgrade user's to IE 7 since it's a beta and also since most of them use mozilla. thanks in advance:
    load: class com.crystaldecisions.ReportViewer.ReportViewer not found.
    java.lang.ClassNotFoundException: com.crystaldecisions.ReportViewer.ReportViewer
         at sun.applet.AppletClassLoader.findClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at sun.applet.AppletClassLoader.loadClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at sun.applet.AppletClassLoader.loadCode(Unknown Source)
         at sun.applet.AppletPanel.createApplet(Unknown Source)
         at sun.plugin.AppletViewer.createApplet(Unknown Source)
         at sun.applet.AppletPanel.runLoader(Unknown Source)
         at sun.applet.AppletPanel.run(Unknown Source)
         at java.lang.Thread.run(Unknown Source)
    Caused by: java.io.IOException: open HTTP connection failed.
         at sun.applet.AppletClassLoader.getBytes(Unknown Source)
         at sun.applet.AppletClassLoader.access$100(Unknown Source)
         at sun.applet.AppletClassLoader$1.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         ... 10 more
    Exception in thread "Thread-5" java.lang.NullPointerException
         at sun.plugin.util.GrayBoxPainter.showLoadingError(Unknown Source)
         at sun.plugin.AppletViewer.showAppletException(Unknown Source)
         at sun.applet.AppletPanel.runLoader(Unknown Source)
         at sun.applet.AppletPanel.run(Unknown Source)
         at java.lang.Thread.run(Unknown Source)
    java.lang.NullPointerException
         at sun.plugin.util.GrayBoxPainter.showLoadingError(Unknown Source)
         at sun.plugin.AppletViewer.showAppletStatus(Unknown Source)
         at sun.applet.AppletPanel.run(Unknown Source)
         at java.lang.Thread.run(Unknown Source)
    Exception in thread "thread applet-com.crystaldecisions.ReportViewer.ReportViewer" java.lang.NullPointerException
         at sun.plugin.util.GrayBoxPainter.showLoadingError(Unknown Source)
         at sun.plugin.AppletViewer.showAppletException(Unknown Source)
         at sun.applet.AppletPanel.run(Unknown Source)
         at java.lang.Thread.run(Unknown Source)

    BigDaddyLoveHandles wrote:
    h1. {color:red}MULTIPOST: [http://forums.sun.com/thread.jspa?threadID=5358840&messageID=10564025]{color}
    That wasn't attention-grabbing enough apparantly. Let's try it again.
    h1. {color:red}MULTIPOST: [http://forums.sun.com/thread.jspa?threadID=5358840&messageID=10564025]{color}
    h1. {color:red}MULTIPOST: [http://forums.sun.com/thread.jspa?threadID=5358840&messageID=10564025]{color}
    h1. {color:red}MULTIPOST: [http://forums.sun.com/thread.jspa?threadID=5358840&messageID=10564025]{color}
    h1. {color:red}MULTIPOST: [http://forums.sun.com/thread.jspa?threadID=5358840&messageID=10564025]{color}
    h1. {color:red}MULTIPOST: [http://forums.sun.com/thread.jspa?threadID=5358840&messageID=10564025]{color}

  • Help! Java no longer works with IE or Firefox

    This all started when I downloaded JRE ...whatever the latest version is. Java was working fine in both browsers. Then I installed JRE so I could run some Java program (which works fine), but now, it doesn't work in the Internet browsers. I tried uninstalling and reinstalling but still it doesn't work.
    Help is appreciated! A lot of basic websites are useless without it. Thanks

    Open the Windows Control Panel, there should be a Java entry. Open it and click the Java tab | Applet Runtime Settings | View, and verify that it shows the 1.5.0_01 JRE.
    Then click the Advanced tab | "<APPLET> tag support"; Internet Explorer should be checked. If it's not, check it.
    Open the IE Tools menu, there should be a Sun Java Console entry. If it's there, click it - it should open the Java Console, showing version 1.5.0_01.
    At this point, IE should work. FF problems are a matter of FF settings, I can't help.
    If after this IE isn't working, then Java is trashed, removal of Java and reinstall is probably needed. It may be necessary to manually clean the Registry. If there are multiple versions, remove them all. Reinstall 1.5.0_01 last.

  • HELP NEEDED for applet posting

    Hi,
    I have a PC with J2SDK1_4_0_01.
    I wanted to publish my first "Hello World" applet on both Netscape 6.2 and IE 6.0. In Netscape it works but on IE it does not. The html and class file are in the same directory. In the Java console I get the following error:
    java.lang.NoClassDefFoundError
    java.lang.ClassNotFoundException: HelloWorld
    I tried using the OBJECT tag under IE and there is no change. Could you please help and tell me what I'm doing wrong? Thanks in advance!
    -- Cristian

    Hi,
    I fixed it. I'm putting it here because it could be of use to some one. So, I had jre 1.3.1 with IE 6.0 and Netscape 6.2 on Windows 2000 Pro and the "applet" tag would not work in neither of them despite the fact that the .html and .class files were in the same directory and the VM from the browsers should have kicked in (could anyone explain it?). Then I uninstalled jre 1.3.1 and downloaded jre 1.4.0. At this moment the "applet" tag worked in NETSCAPE (loaded and showed the applet) and in IE would still not work despite having the plug-in setup for both browsers at installation time.
    I decided to try the "object" tag in IE with "codebase" targeted to Sun's location of the 1.4.0 plug-in. To my surprise it would not recognise that it is already installed and would ask for it from SUN. After the download and in the middle of the installation would stop and pop-up a window saying "You already have plug-in 1.4.0 - Do you want to uninstall it?".
    So I uninstalled the previous copy and let the automatic download and installation take place. And, after this second installation through the OBJECT tag it works both for Netscape and IE, and with all tags: applet, object and embed!
    Now may I ask you why do we need this very complex technology to achieve such a simple task?
    -- Cristian

  • Java Applets not working with Firefox 5 properly

    Java Applets work sometime. But after sometime the Java icon at the bottom (near date & time) disappears. After this no matter what I do it does not work. Java Applets are used in this case to draw charts. The same charts come out properly in Internet Explorer. But I prefer using Firefox for its speed. What is the reason for this problem ?

    -> Tap ALT key or press F10 to show the Menu Bar
    -> go to Help Menu -> select "Restart with Add-ons Disabled"
    Firefox will close then it will open up with just basic Firefox. Now do this:
    -> Update ALL your Firefox Plug-ins https://www.mozilla.com/en-US/plugincheck/
    -> go to View Menu -> Toolbars -> unselect All Unwanted toolbars
    -> go to Tools Menu -> Options -> Content -> place Checkmarks on:
    1) Block Pop-up windows 2) Load images automatically 3) Enable JavaScript
    -> go to Tools Menu -> Options -> Privacy -> History section -> ''Firefox will: '''select "Remember History"'''''
    -> go to Tools Menu -> Options -> Security -> place Checkmarks on:
    1) Warn me when sites try to install add-ons 2) Block reported attack sites 3) Block reported web forgeries 4) Remember Passwords for sites
    -> Click OK on Options window
    -> click the Favicon (small drop down menu icon) on Firefox SearchBar (its position is on the Right side of the Address Bar) -> click "Manage Search Engines" -> select all Unwanted Search Engines and click Remove -> click OK
    -> go to Tools Menu -> Add-ons -> Extensions section -> REMOVE All Unwanted/Suspicious Extensions (Add-ons) -> Restart Firefox
    You can enable your Known & Trustworthy Add-ons later. Check and tell if its working.

  • On a Mac Java applets not working on FF 31, have not worked since FF26; how to fix?

    KeepVid, Quietube, Pin It, and placeholders on most websites instead of Java applets. Running Mavericks and Mountain Lion on an iMac and MacAir, and the applets don't work on either - they haven't worked since FF26. Plug-in is installed, and "always activate" in on. Anyone know what's going on and how to fix this?

    I know of two settings associated with Java, maybe we can start there?
    About:addons and then go to "extensions". Look for the Java plugin and make sure it is activated.
    After this you can go to the Java options to make sure that it is active and check if it is up to date here [https://www.mozilla.org/en-US/plugincheck/]
    [https://support.mozilla.org/en-US/kb/how-allow-java-trusted-sites How to allow Java on Trusted Sites in Firefox] may also be helpful.

  • Help with java applets

    Ok i know i haven't read the applet tutorial or had much experience with applets but just hear me out and see if you can help me.
    BACKGROUND
    Ok...so i have previously viewed an applet on windows viewing an html file on my computer. I am trying to view just the most simple applet (helloworld) on linux. I'm using Ubuntu linux, the latest version as of February 23, 2006.I created an applet file and an html file in the same directory with the html file having an <applet> tag in it linking to the HelloWorldApp. I have tried viewing the html file and the java applet won't load. Everything other than the applet worked and I'm just stuck.
    So my plea is would somebody please just paste the bare minimum html file and applet file that you can see an applet with? I want to learn about applets and will do the tutorial but I would really like to just see one.
    Please help,
    A frustrated applet noob
    p.s.
    According to java.com I have installed JRE 5.0 and i have compiled a java application so I'm pretty sure I have successfully installed JDK 5.0.

    Bob, what web browser are you using?
    Make sure that the browser supports Java applets.
    If you want just to debug your applet try appletviewer utility
    from JDK first.

  • Java Applets not working using IE 6 after uninstalling software

    I uninstalled some software on WinXP using Add/Remove, however the software still left remnants on my system. I tried to removing all the entries in the registry with RegEdit....I will confess I am a rookie with that tool, however now IE 6 will not launch Java Applets on the web sites I visit.
    I also have Mozilla Firefox 8 installed and Java Applets work fine using that browser. Do I have to reinstall WinXP to correct IE 6, or is there an easier alternative?
    Thanks for any suggestions
    Gerry

    Please check out in the IE Explorer Tools--> Internet Options --> in this Advanced tab this will display you with the set of options and chceck boxes...
    in that please check out that whether the Java(SUN) --- (USe Java....<applet> Requires reStart...
    is existing or not if existing please check it and restart the system.
    if it is not existing in your broser then you have to install the JRE in the system for your Applet to work..
    That can be downloaded form...
    http://www.java.com/en/download/manual.jsp
    Here go for windows....
    All The Best..

Maybe you are looking for

  • Security of Tape Backups

    Michael beat me to it; the first question that I would ask is if you should still be using tape.Tape was popular primarily because you could get a lot on a tape, much more than on a disk; one tape was often sufficient to backup several drives. That c

  • How to make my display be the main view with my mac Book Pro

    How to set up my external display automatically work as the main display when plugged into my MacBook Pro. I had it set up to work this way on my old MBP but I got a new MBP with Mountian Lion and the Display set up seen different and I can figure ou

  • Do not get printouts for some custoemrs through background job

    Hi , I am getting the printouts through back ground jobs, suppose what ever the billing documents by end of the day and there is back ground job which runs and give the print outs for that i have maintained in VV31 medium 1 printout and dispatch time

  • FBL3N screen layout is in disable

    Dear Experts , Can you tell me in TC FBL3N , screen layout ikon shows disable , how i can make  enable tell how this  screen layout settings locked and unlocked for newly create screen layout Thanks Bhaskar

  • Brush location

    I am about to build a new computer and I'm going to use the same hard drive so its going to be reformatted; I have quite a few downloaded brush set that i would like to keep but I can't find the files to transfer to a external hard drive. I looked un