Link to home
Start Free TrialLog in
Avatar of checkso
checkso

asked on

Change the table or a TD height dynamically

Hi,

Is there a way to change the height and width of the table or a TD dynamically using javascript.

In my code, I change one table accordign to their personal settings. But then the other table is draged up and there is a empty space at the botton of the window.

Can we resize the second table to use this space.

Thanks,
Checkso
Avatar of Michel Plungjan
Michel Plungjan
Flag of Denmark image

document.getElementById('tableId').height = 400

Like
<table id=t1 height=200 border=1><tr><td onMouseOver="document.getElementById('t1').height = 400">Hello</td></tr></table>
Avatar of Nushi
Nushi

or it can be done using style as well:

document.getElementById('Id').style.height = 400

Nushi.

ASKER CERTIFIED SOLUTION
Avatar of Nushi
Nushi

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
as i learned form ms
you can do it in the form by using:

document.formName.tableId....

Nushi.
No comment has been added lately, so it's time to clean up this TA.
I will leave the following recommendation for this question in the Cleanup topic area:

Accept: mplungjan {http:#9963700}

Please leave any comments here within the next four days.
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

jAy
EE Cleanup Volunteer