Solved

Using HashMap in the struts <html:option> tag

Posted on 2004-08-24
4
774 Views
Last Modified: 2008-03-17
Hi,
I know you can use a HashMap with the otpions like:-
      <html:options collection="userBaskets" property="key" />
but if the value of in HashMap is an object, how do you use a property of the value as the label,

eg   <html:options collection="userBaskets" property="key" labelproperty="value.getName()"/>
0
Comment
Question by:mikehalfsheen
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 35

Accepted Solution

by:
TimYates earned 250 total points
ID: 11878968
<html:options collection="userBaskets" property="key" labelproperty="value.name"/>

?
0
 
LVL 35

Expert Comment

by:TimYates
ID: 11878972
Can you post some code? (assuming that doesn't work)?
0
 

Author Comment

by:mikehalfsheen
ID: 11879084
lovely ;)
0
 
LVL 35

Expert Comment

by:TimYates
ID: 11879151
:-)  Woo!  

Good luck!

Tim
0

Featured Post

[Webinar] Code, Load, and Grow

Managing multiple websites, servers, applications, and security on a daily basis? Join us for a webinar on May 25th to learn how to simplify administration and management of virtual hosts for IT admins, create a secure environment, and deploy code more effectively and frequently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
spring AOP 6 94
Set up Wildfly 10 8 471
JavaScript parse form with colon separated values 2 79
jsp login check 12 67
Had a business requirement to store the mobile number in an environmental variable. This is just a quick article on how this was done.
In this series, we will discuss common questions received as a database Solutions Engineer at Percona. In this role, we speak with a wide array of MySQL and MongoDB users responsible for both extremely large and complex environments to smaller singl…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…
Suggested Courses

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question