Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to get value from dynamic textfield

 
manish krishnan
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi in my application i have to display text-fields dynamically. now my problem is how to retrieve data of the field in action.
please help me.. give me some idea.
 
lokesh pattajoshi
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

You can give text field name dynamically and retrieve the value using that dynamic name.

Regards,
Lokesh
 
manish krishnan
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi lokesh
can you explain with an example.. do you know any link for referring..
 
lokesh pattajoshi
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think you will be creating dynamic text boxes in loop follow example below\



Hope it helps you.

Regards,
Lokesh

 
manish krishnan
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Lokesh can we implement this in Struts.

Thanking You
Manish
 
lokesh pattajoshi
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes why not in action also you can get value from request parameter.
 
Jaimesh M Ponkia
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you are using a tag lib to display the text box, then have a list which would hold the property of the text box and iterate through the list to display the text box.
 
manish krishnan
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
is it possible to get name, value pair from Value Stack

Thanking You
Manish
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic