can you specify the code to access individual elemets of the list in the jsp
i tried
<logic:iterate id="element" name="list" scope="request">
Element Value: <bean:write name="element" /><br />
</logic:iterate>
and i got a whole list and it printed two times since it has two elements
On Wed, 18 Aug 2004 VAN BROECK Jimmy wrote :
>Hmm, i don't think your Passaction code is complete??
>
>With this code, you would already get an nllpointerexception on the v variable!
>
>Aren't you missing something?
>
>Otherwise: try Vector v=new Vector();
>
>-----Original Message-----
> From: vineesh . kumar [mailto:[EMAIL PROTECTED]
>Sent: woensdag 18 augustus 2004 9:13
>To: [EMAIL PROTECTED]
>Subject: Accessing collections in jsp
>
>
>
>To pass a range of values i used
>in PassAction.java
> Vector v=null;
> v.add("somestring");
> v.add("someotherstring");
>
>request.setAttribute("name",v);
>
>and in the jsp i tried to access it like
>
> <logic:iterate id="mylist" name="list">
> Element Value: <bean:write name="mylist" /><br />
></logic:iterate>
>
>but i got an error saying
>
>javax.servlet.ServletException: Cannot find bean list in scope request
>
>anyone know wat is this problem
> my struts-config action mapping is
>
>
><action
> path="/accountslisting"
> type="com.c2rmnet.struts.action.AccountslistAction"
> validate="false">
> <forward name="success" path="/form/AccountListing.jsp" />
> <forward name="invalidsession" path="/form/InvalidSession.jsp" />
> </action>
>
>Thanks
> vinu
>
>
>STRICTLY PERSONAL AND CONFIDENTIAL
>This message may contain confidential and proprietary material for the sole use of
>the intended recipient. Any review or distribution by others is strictly prohibited.
>If you are not the intended recipient please contact the sender and delete all copies.
>
>Ce Message est uniquement destiné aux destinataires indiqués et peut contenir des
>informations confidentielles. Si vous n'êtes pas le destinataire, vous ne devez pas
>révéler le contenu de ce message ou en prendre copie. Si vous avez reçu ce message
>par erreur, veuillez en informer l'expéditeur, ou La Poste immédiatement, avant de le
>supprimer.
>
>Dit bericht is enkel bestemd voor de aangeduide ontvangers en kan vertrouwelijke
>informatie bevatten. Als u niet de ontvanger bent, dan mag u de inhoud van dit
>bericht niet bekendmaken noch kopiëren. Als u dit bericht per vergissing heeft
>ontvangen, gelieve er de afzender of De Post onmiddellijk van op de hoogte te brengen
>en het bericht vervolgens te verwijderen.