aspose file tools
The moose likes JSP and the fly likes Checkbox inside table in JSP Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » JSP
Reply Bookmark "Checkbox inside table in JSP" Watch "Checkbox inside table in JSP" New topic
Author

Checkbox inside table in JSP

Neha k Agrawal
Greenhorn

Joined: Mar 25, 2008
Posts: 25
Hello All ,
I am doing one project in that I want to insert checkbox inside table according to the data fetch from database.There will be 3 check boxes in my table on JSP page.There is one field in my table called "Status".
If Status field value is 1 , first check box (Enable ) should get checked.
If Status field value is 2 , first check box (Disable ) should get checked.
If Status field value is 3 , first check box (Deleted ) should get checked.

I am not getting how to do it.I have tried one grid tld.But it is not working.I am new to this language.Please help me.Any sample code or idea of how to do it will be really helpful.Thanks in advance.
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 26192
    
  66

Neha,
What do you have so far? Can you output the three checkboxes? Can you output a message if the status is equal to 1, 2 or 3?


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
Satya Maheshwari
Ranch Hand

Joined: Jan 01, 2007
Posts: 368
Originally posted by Neha k Agrawal:
Hello All ,
I am doing one project in that I want to insert checkbox inside table according to the data fetch from database.There will be 3 check boxes in my table on JSP page.There is one field in my table called "Status".
If Status field value is 1 , first check box (Enable ) should get checked.
If Status field value is 2 , first check box (Disable ) should get checked.
If Status field value is 3 , first check box (Deleted ) should get checked.

I am not getting how to do it.I have tried one grid tld.But it is not working.I am new to this language.Please help me.Any sample code or idea of how to do it will be really helpful.Thanks in advance.


Hi Neha
I was a bit confused on reading your question. Do you have 1 or 3 checkboxes in the table. Also, how is the Status field related to the 3 checkboxes.


Thanks and Regards
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: Checkbox inside table in JSP
 
Similar Threads
Problem in getting the state of checkbox
In struts el how to get checkbox status
Maintain checked and unchecked in checkbox in pagination
how to retain checkbox status during pagination in struts
Problem while retriving data