Erro da consulta da lista

7 respostas
potter

oi galera , alguem poderia me ajudar
esta dando um erro no meu progeto na parte final para consultar uma lista

<%@ page import="modelo.*" %>
<%List l=(ArrayList)request.getAttribute("l");%>    

<% for(int i=o <; i < l.size(); i++ ){
Fake f=(Fake) l.get(i); %>

<table align="center" width="400px" border="1">
            <tr>
                <td align="center" colspan="4">
                    Emails e Senhas:
                </td>
            </tr>
            <tr>                
                <td>
                    Emails:
                </td>
                <td>
                    <%out.print(...);%>
                </td>
                <td>
                    Senhas:
                </td>
                <td>
                    <%out.print(...);%>
                </td>
            </tr>          

<%}%>

7 Respostas

furutani

Poderia detalhar o erro?

potter

<%[color=red]List[/color] l=([color=red]ArrayList[/color])request.getAttribute(“l”);%>

[color=red]<% for(int i=o <;; i < l.size(); i++ ){
Fake f=(Fake) l.get(i); %>[/color]

onde ta vermelho ta o erro

furutani

Certo… e qual a mensagem de erro?

potter

cannot find symbolsymbol : class listlocation: class SimplifieldJSP ServletCannot find symbolsymbol : class ArrayListLocation : class SimplifiedJSPServlet

esse e o do 1° erro

furutani

a imagem não aparece aqui

potter

ileegal start of expressioncannot find symbolsymbol : variable olocation:class simplifieldJSPserviletcannot find symbolsymbol:method size()location:class List

do segundo erro

potter

Garnde parte do erro consegui resolver era imports que tava faltando da list e arraylist ,

  • agora ainda ta com dois erros

<%@ page import=“modelo."%<%@ page import=“java.util.List;;”%>
<%@ page import="import java.util.
;”%>

<%List l=(ArrayList)request.getAttribute(“l”);%>

<% for(int i=0 ; i < l.size(); i++ ){
[color=red]Fake f=(Fake) l.get(i);[/color] %> <<<ERRO: cannot find symbolsymbol:class fakelocation:class:SimplifiedJSPServletunexpected typerequired classFound:indentiffier(31)

Criado 28 de novembro de 2009
Ultima resposta 28 de nov. de 2009
Respostas 7
Participantes 2