Erro em applet

2 respostas
R

Galera,

Estou recebendo esse erro no IE ao chamar meu applet..

Java Plug-in 1.5.0_15
Using JRE version 1.5.0_15 Java HotSpot(TM) Client VM
User home directory = C:\Documents and Settings\Administrator
Clear classloader cache ... completed.
load: class com.tcc.AgendaLista.class not found.
java.lang.ClassNotFoundException: com.tcc.AgendaLista.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)

Mas seguinte, o html que estou usando
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<applet code="com.tcc.AgendaLista.class" width=200 height=200>
</applet>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>

</body>
</html>

Está junto do arquivo.class em
C:\Documents and Settings\Administrator\workspace\projetoTCC\build\classes\com\tcc\AgendaLista.class
C:\Documents and Settings\Administrator\workspace\projetoTCC\build\classes\com\tcc\Teste.html

Estou usando o eclipse...alguma dica ? Detalhe: no elipse funciona !

valeu!

2 Respostas

R

Essa é a classe que está em C:\Documents and Settings\Administrator\workspace\projetoTCC\src\com\tcc\AgendaLista.java

package com.tcc;


import java.awt.Graphics;
import javax.swing.JApplet;

public class AgendaLista extends JApplet {  

	public AgendaLista(){}

   public void paint( Graphics g )
   {

      super.paint( g );
      g.drawString( "teste !", 25, 25 );

   } 

}
R

aih galera ! alguma dica ?

Criado 27 de outubro de 2008
Ultima resposta 28 de out. de 2008
Respostas 2
Participantes 1