Click here to Skip to main content
15,896,486 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am working in a project in which i need to arrange controls by defined position in a repeatable control.

I use table as a repeatable control but when I set position of a cell relative and set all children positions absolute then the cell doesn't get width and height.

I have tested this:
XML
<table border="1" style="position:absolute;right:10px;top:20px">
    <tr>
        <td style="position:relative;"><div style="background-color:Red;width:100px;height:40px;position:absolute;top:0;right:0"></div></td>
    </tr>
    <tr>
        <td style="position:relative"><div style="background-color:blue;width:100px;height:40px;position:absolute;top:0;right:0"></div></td>
    </tr>

</table>


I need, each control appears in each cell.
Posted
Updated 27-Jul-10 20:22pm
v2
Comments
koool.kabeer 28-Jul-10 4:17am    
try by setting the width of 'table' element.... since it is the parent so you must first set the width of parent element.... then check

1 solution

It's better to use div's than tables.

Check this[^] for more on div's.
 
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