• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Devaka Cooray
  • Knute Snortum
  • Paul Clapham
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Bear Bibeault
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Ron McLeod
  • Piet Souris
  • Frits Walraven
Bartenders:
  • Ganesh Patekar
  • Tim Holloway
  • salvin francis

logic:iterate  RSS feed

 
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

In the following piece of code I am trying to select in the dropdown box the "buId" when equal to the "bu" set in the form and add the other "buchoices" to the drop down list.

"buchoices" has been initialised to {"Abc", "def", "ghi"} in the action class using the set method from the form. And "bu" has been set to "Abc" in the similar manner.

I am failing on 2 counts
1. selecting the value in the drop down when buId == bu
2. showing the rest of the list on the webpage to the user

(timeDetails is the name of the form bean which has has been declared using the usebean tag.)



Any help on how i can do this will be greatly appreciated.

Thanks a bunch
Achal Jalan
 
pie sneak
Posts: 4727
Mac Ruby VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
<html:select property="bu">
<html:options property="buchoices"/>
</html:select>

Do that and Struts will take care of the rest.
[ March 22, 2005: Message edited by: Marc Peabody ]
 
It is difficult to free fools from the chains they revere - Voltaire. tiny ad:
how do I do my own kindle-like thing - without amazon
https://coderanch.com/t/711421/engineering/kindle-amazon
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!