Using the iterate tag to create the HTML for table is no different than
creating any type of HTML. 

You might take a look a the struts-exercise-taglib example in the
distribution. This tests iterating over a String array and an ArrayList.
You could try placing this page in your application, substituting your
own JavaBeans, and continuing from there. 

Of course, in a production application, the beans should be created in
an Action and forwarded to a page, rather than be created by scriplets
as is done on the test page. But having a page like this can be very
handy for initial development.


Xin Li wrote:
> 
> Hi,
> 
> I tried to use logic:iterate to populate a table. I used
> <logic:iterate id="i_tableArr" name="keyTableArray" indexId="row_index">
>         <tr><td>this is the test page</td></tr>
> </logic:iterate>
> 
> KeyTableArray is the attribute, which contatains an ArrayList.
> 
> When I try to run the the application, it gave me the following error:
> 
> org.apache.jasper.compiler.CompileException: Unable to find setter method
> for attribute: indexId
> 
> Can anybody tell me why this happens?  I would appreciate if an example of
> how to use iterate to populate a table is provided.
> 
> Xin
> 
> --
> To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to