aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes Edit & Delete Table Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Edit & Delete Table" Watch "Edit & Delete Table" New topic
Author

Edit & Delete Table

Bacchi Gerem
Ranch Hand

Joined: Jan 23, 2004
Posts: 120
Hi,
Sample code:

<script type="text/javascript">
function addRow(content,morecontent)
{
if (!document.getElementsByTagName) return;
tabBody=document.getElementsByTagName("TBODY").item(0);
row=document.createElement("TR");
cell1 = document.createElement("TD");
cell2 = document.createElement("TD");
textnode1=document.createTextNode(content);
textnode2=document.createTextNode(morecontent);
cell1.appendChild(textnode1);
cell2.appendChild(textnode2);
row.appendChild(cell1);
row.appendChild(cell2);
tabBody.appendChild(row);


}
</script>

How can i delete a row and edit a row in a table.

If i select a row in a table to edit i get the information in textboxes.

I want to change the value in text box .

Thanks
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
Delete row: http://developer.mozilla.org/en/docs/DOM:table.deleteRow

Edit: look at the cells' innerHTML

Eric
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Edit & Delete Table