• 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

Displaying Data From Different Tables in .jsp

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

I'm having a little trouble (for some reason) understanding how to do something in my Struts 1.3 application.

Specifically, I have a .jsp that looks (in part) like below:




The action in struts-config looks like this:





The question I have is how do I display data from different classes (beans) in my drop down lists on my .jsp. My action points to a specific actionForm (in this case "ProblemForm") but I want to display data from another bean (in this case UseCases) in my drop down list on the same .jsp page. Also, I'm using hibernate 3 and there is a "many-to-many" relationship between "Problem" bean and "UseCase" bean. The relevant section of the "ProblemActionForm" is shown below as well:




I guess what I'm asking is given the above what should the code be in my .jsp to show the various "use case" values? Apparently this code above:



is incorrect.


Any help is appreciated,

Thanks,

Rob
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

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

Thanks for the response . . . sorry for not responding sooner . . . I've been out of the office . . .

I did exactly as you suggested and now I get the following error:

"javax.servlet.jsp.JspException: No getter method available for property useCaseId for bean under name org.apache.struts.taglib.html.BEAN"

Do you know why I'm getting this error?

Thanks,

Rob


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

I was able to solve this problem . . . thanks for your assistance . . .

Rob
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please follow up in case someone else encounters the same issue. Thanks! Glad you got it working.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic