Erro the serializable no Eclipse

1 resposta
adriano_avelino

Eu tenho uma classe que utilizo ela perfeitamente no netbeans, porém instalei o eclipse por ser mais leve. Quando aplico essa classe no eclipse apresenta o seguinte erro:

the serializable class does not declare a static final serialversionuid field of type long

Isso é alguns erro por ter os dois aplicativos?

segue o código:

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package teste;

import java.awt.Container;
import javax.swing.JFrame;
import javax.swing.JTextField;

/**
 *
 * @author Adriano
 */
public class Janela extends JFrame{

    public Janela(){
        super("janela");
        Container c = getContentPane();
        c.setLayout(null);
        
        JTextField botao = new JTextField();
        botao.setBounds(10, 10, 200, 20);
        
        c.add(botao);
        
        setSize(300, 300);
        setDefaultCloseOperation(EXIT_ON_CLOSE);
        setVisible(true);
        
        
    }

    
    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        Janela janela = new Janela();
    }
}

1 Resposta

M

poste seu bean…

Criado 23 de junho de 2012
Ultima resposta 23 de jun. de 2012
Respostas 1
Participantes 2