• 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 an ActionForm

 
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am trying to display data from an ActionForm in a jsp page. I want to just write static text. This doesn't work:


But this does (with an html:form):


The bean:write doesn't throw any errors, it just doesn't display anything.
So confused...
 
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My best guess would be that "dataSource" does not match exactly what you put in your struts-config.xml file as the form bean to be used by the action.

Do you have the following Entry in your struts-config.xml?

<action name="dataSoure" path="/myAction" ..>

In this case, "myAction" is whatever action is specified in your <html:form> tag.
 
Andrew McLaren
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Merrill Higginson:
My best guess would be that "dataSource" does not match exactly what you put in your struts-config.xml file as the form bean to be used by the action.

Do you have the following Entry in your struts-config.xml?

<action name="dataSoure" path="/myAction" ..>

In this case, "myAction" is whatever action is specified in your <html:form> tag.



Aha! That was it, thanks a ton!

Andrew
reply
    Bookmark Topic Watch Topic
  • New Topic