• 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

how to edit data on a form

 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
HI i am new bie to struts, i want to edit data on a form.
i have a single form , through which i enter the data into the database.
now i want to use this form only and want to edit the data, so is there any ting.

i am using Dispatch Action,

looking forward for a positive response.

Thanking you
Chetan kokil
 
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
in your actionclass method have something like this

Object obj = new Object();
PageForm oForm= (PageForm) form;

oForm.setName(obj.getName());
oForm.setId(obj.getId());

in jsp:
<html:text property="name"/>

'PageForm' == your actionForm
'Object' == your object class
oForm.setName() == will set the respective property value to the form
 
reply
    Bookmark Topic Watch Topic
  • New Topic