File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes selecting a table row with 3 columns and  sending it to another page. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "selecting a table row with 3 columns and  sending it to another page." Watch "selecting a table row with 3 columns and  sending it to another page." New topic
Author

selecting a table row with 3 columns and sending it to another page.

Vishnu Prakash
Ranch Hand

Joined: Nov 15, 2004
Posts: 1026
I have a page with three text boxes and a add button. on click of the button another page opens which has a table with 3 columns and 10 rows(all static data). Any one row can be selected at a time and on submit the selected row values has to come to the three text boxes. I using struts framework.

I had done the jsps, but couldn't proceed with how to implement the submit of selected row to the text boxes.

Any suggestion is highly appreciated.


Servlet Spec 2.4/ Jsp Spec 2.0/ JSTL Spec 1.1 - JSTL Tag Documentation
Amit M Tank
Ranch Hand

Joined: Mar 28, 2004
Posts: 257
From your question I got to know the following. You have 3 text boxes and an "Add" button. when you click on the add button you open a popup(or next page as the case may be) which has a table with 3 columns and lot of rows. When you click on one of the row you want the data of that row to be populated in the main page.

If you are using a popup then you can use javascript to get the data of the popup and populate the main page and close the popup.

If you want having the data on a page and you want to fwd it to the page which has 3 textbox and add button. You can do a submit of the form to a url(this url should be something.do) and pass the parameter like Id=1001, in your struts action you can get the id and do the processing and fwd it to the page you want.

Hope this helps.

Thanks,
Amit Tank


Amit Tank
Linked In
Vishnu Prakash
Ranch Hand

Joined: Nov 15, 2004
Posts: 1026
Can some one kindly give me more input to this?
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: selecting a table row with 3 columns and sending it to another page.
 
Similar Threads
How to Populate a Table from ResultSet
JSP- finding the table row selected
RadioButtons in jsp
Column value is getting reset to zero automatically in Jtable
Dynamic generation and removal of form elements in struts1