|
A clear statement of what you need to accomplish, without posing a
particular implementation, might be helpful. I'm not exactly sure what it is you
need to do. My first guess is that the part about "count" should be encapsulated
in a bean, and not exposed to the JSP. But I'm not sure if I understand the
business or application logic behind your question well enough.
*********** REPLY SEPARATOR *********** On 12/27/2000 at 8:51 AM Chandan Kulkarni wrote: Actually OrderItem is an object with several fields. I trimmed
it down to just one field to simplify the problem. So "items" is an ArrayList of
OrderItems.
I couldn't find the right combination of nested/indexed
property names for the form:text tag to generate the correct input tag. Here's
what I tried...
<form:text name="orderItems" property="<%= "orderitems["
+ count + "]" %>"
value="<%= ((OrderItem)orderlist).getItemNumber() %>" /> When it can't find the correct property name in the bean it
gives a compilation error. I used a run-time expression to create
items[0].itemName. In this case the form:text tag is just ignored and is left in
the html generated just as is...
It seems the only way to use an indexed/nested property name
is to use the <input> tag itself.
I am using the struts 12/15 build....
Thanks,
-Chandan
|
- Help: <logic:iterate> and form input fields Chandan Kulkarni
- Re: Help: <logic:iterate> and form input field... Ted Husted
- Re: Help: <logic:iterate> and form input field... Chandan Kulkarni
- Re: Help: <logic:iterate> and form input field... Chandan Kulkarni
- Re: Help: <logic:iterate> and form input field... Chandan Kulkarni
- Re: Help: <logic:iterate> and form input f... Mishkin Berteig
- Re: Help: <logic:iterate> and form input field... Chandan Kulkarni
- Re: Help: <logic:iterate> and form input f... Mishkin Berteig
- Re: Help: <logic:iterate> and form input field... Chandan Kulkarni

