Click here to Skip to main content
15,895,084 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi all,


I have to show data in Table control on click event of a button with database .Please help me.


Thanking You
Posted
Comments
Manas Bhardwaj 28-Jan-11 5:35am    
What have you done so far?
Mohd Wasif 28-Jan-11 5:56am    
Actually i displayed data in table but don't know how to put header and footer in table.

You have to construct the table at runtime and then place it in pre-defined panel/placeholder.
Create a table and then define columns of it and then add rows one-by-one.

Try!
 
Share this answer
 
User Table, TableRow and TableCell Class to construct the table. When Generating TableCell, bind the database value with in that.

Let me know if you need any further help !
 
Share this answer
 
First let me clear one thing. Server side Table and client Tables are completely different.

When you are dealing with HtmlTable, TableRow or TableCell, those are actually mapped / rendered into client Table, tr and td.

So if you are doing this for client side I think you need to deal with client side html tags, and when the tag is clicked you can go to server.

Check
http://www.w3schools.com/aspnet/control_table.asp[^]
:thumbsup:
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900