File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes Struts layout:select Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Struts layout:select" Watch "Struts layout:select" New topic
Author

Struts layout:select

murali karthik
Greenhorn

Joined: Mar 16, 2006
Posts: 2
Hi,

I have a small peice of code in my jsp as

<layout:select mode="E,I,I" key="label.mndtyVlntryIn" property='prdWIGnrtnRuleData.mndtyVlntryIn'>
<layout ption value="0" key="combo.select.none"/>
<layout ptions collection="d_CA_RuleMndtyVlntryIN" property="key" labelProperty="value" />
</layout:select>


Suppose the collection d_CA_RuleMndtyVlntryIN has 4 values a,b,c,d
How can i set the value 'a' as default in my combo box....

Any suggestions appreciated..
Brent Sterling
Ranch Hand

Joined: Feb 08, 2006
Posts: 948
I have no idea how the layout tags work. Using the html tags, I would just set a default value for the field in my form. I would usually do this in the action that is used to display the page.

- Brent
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Struts layout:select
 
Similar Threads
Using hashmap with html:options
How to retrieve property and labelProperty info from action class
why the window doesn't close and bring the item to the main form?
with html : options tag
Problem in struts layout's datagrid.