• 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
  • Tim Cooke
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Liutauras Vilda
  • Henry Wong
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Mikalai Zaikin
  • Himai Minh

textbox values in the action..

 
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am using struts 2.. I have number of textbox where the user can key in different values..

If the variable name is "value" I used the getValue() methods in action to access the newly entered values but it shows me only the old values and not the latest

let me know If I am doing something wrong..
 
Ranch Hand
Posts: 349
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
posting the code for your getter, setter, and jsp tag to display the field would help, as well as the html source for the field.
 
rahulJ james
Ranch Hand
Posts: 123
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am not getting your point. Do you mean to say that I have to use a getter setter methods in the action side, I have those methods already and I am not able to get the results...

One more stuff here is something like below,

<html:textfield name="name" size="5" value="<html roperty value="name"/>" />

When I give this its not even compiling.. lemme know if there is anything wrong in my approach
 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think for property in struts form bean, just use:
<html:form action="">
<html:textfield property="name"/>
</html:form>

where the property 'name' is you struts action form, the value will be fetch automatically.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic