• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Populating List box in the JSP from Action Class

 
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I am using struts framework

I have a jsp page where i have 3 list boxes in which i need to populate the data on the page load

but i have to populate the data in the second list box after selecting a value in the first list box WITHOUT MAKING A DATABASE CALL.

when i first load the page i need to save the data somewhere
any ideas
i have Business Objects, Transfer Objects,ViewHelpers in my project

where can i implement this logic and how to do it any suggestions please!!!
 
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The term used for this type of control is "dependent dropdown" or "dependent select". If you Google either of these topics, you will find a lot of suggestions about how to do it.

This topic has also been discussed recently in this thread
 
Ranch Hand
Posts: 948
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
When you say "WITHOUT MAKING A DATABASE CALL" do you really mean "without refreshing the page"? If so, I would recommend an Ajax based solution. As long as your lists are not too large, loading the data into the page and using client-side JavaScript is not too bad of a solution either.

- Brent
 
Chinni Bujji
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes
One Data Base Call
But i ll refresh the page

but the data is very large

so give me some suggestions
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic