aspose file tools*
The moose likes Servlets and the fly likes how to manage values of disabled cells in a row to the actionServlet in a loop? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "how to manage values of disabled cells in a row to the actionServlet in a loop?" Watch "how to manage values of disabled cells in a row to the actionServlet in a loop?" New topic
Author

how to manage values of disabled cells in a row to the actionServlet in a loop?

Rd Dari
Ranch Hand

Joined: Feb 22, 2010
Posts: 202

Hi All,

I am trying to insert a data in another table which come from different table in a jsp page and want to insert only enabled data of a particular row.

Please guide me.

here is my jsp and servlet.......









SERVLET IS
Rd Dari
Ranch Hand

Joined: Feb 22, 2010
Posts: 202

what is the solution for the above problem can anyone suggest me what should I use in my Servlet and JavaScript to avoid this problem.


Thanks in advanced!
Martin Vajsar
Sheriff

Joined: Aug 22, 2010
Posts: 3434
    
  47

I've moved your post to the Servlets forum; it's more likely to get an answer there. Please see CarefullyChooseOneForum (⇐ click).
Nicola Garofalo
Ranch Hand

Joined: Apr 10, 2010
Posts: 308
You want to insert data into a database
Those data come from an html table, is that correct?

Start to move all the sql operations away from your jsp. Move them in the servlet.
A jsp file is used to show data, not to perform database operations.

In the same way move all html code away from your servlet and put it in a jsp. Servlet shouldn't build html anymore.

The steps are:

1) Put the Input mask in a jsp with all javascript and html stuff. When you are done you can post your jsp.
2) Let the Servlet get the parameters, perform database operations and forward control to a jsp. When you are done post the servlet code.


If the input mask parameters are disabled they arrive as null Strings to the servlet, so you can check them before performing the insert query.

Waiting for your jsp and servlet.



Bye,
Nicola
Rd Dari
Ranch Hand

Joined: Feb 22, 2010
Posts: 202

As you recommend THIS IS JSP



And This SERVLET



I need a good solution to set NA in that cells values which is disabled in jsp page. How it is possible.
Rd Dari
Ranch Hand

Joined: Feb 22, 2010
Posts: 202

Hi, guys its my Servlet which I missed yesterday with the above post

Please give me a solution to add value(blank or "NA") in disabled cell

Thanks in advanced
Rd Dari
Ranch Hand

Joined: Feb 22, 2010
Posts: 202

any ways I have done it using JavaScript


 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to manage values of disabled cells in a row to the actionServlet in a loop?
 
Similar Threads
How to update a image using servlet?
Select All
Close...but no cigar? Help with Check boxes
problem in getting values using EL
how to enable and disable in a multiple row only to click a checkbox,radio button?