Hi,
We have a RadComboBox with an ItemTemplate. If we specify it like this:
<ItemTemplate>
<asp:Panel ID="panelMyPanel" runat="server" Height="55px"
Width="100%">
<table align="left" cellpadding="2" cellspacing="2" class="style1">
<tr>
<td width="50%" bgcolor="#990099">
<asp:Label ID="Label370" runat="server" Text="My text></asp:Label>
</td>
<td width="50%" bgcolor="#9933FF">
<asp:Label ID="Label370" runat="server" Text="My text></asp:Label>
</td>
</tr>
</table>
</asp:Panel>
</ItemTemplate>
It will "drift" for each row (no vertical alignment) despite no text being close to long enough to fill the 50% for each column. If we change to:
<ItemTemplate>
<asp:Panel ID="panelMyPanel" runat="server" Height="55px"
Width="600px">
<table align="left" cellpadding="2" cellspacing="2" class="style1">
<tr>
<td width="300px" bgcolor="#990099">
<asp:Label ID="Label370" runat="server" Text="My text></asp:Label>
</td>
<td width="300px" bgcolor="#9933FF">
<asp:Label ID="Label370" runat="server" Text="My text></asp:Label>
</td>
</tr>
</table>
</asp:Panel>
</ItemTemplate>
It will render correctly.
Shouldn't both work and produce the same result? We prefer to specify width in % instead of PX as that will work even if page skin or similar is changed in the future.
We have a RadComboBox with an ItemTemplate. If we specify it like this:
<ItemTemplate>
<asp:Panel ID="panelMyPanel" runat="server" Height="55px"
Width="100%">
<table align="left" cellpadding="2" cellspacing="2" class="style1">
<tr>
<td width="50%" bgcolor="#990099">
<asp:Label ID="Label370" runat="server" Text="My text></asp:Label>
</td>
<td width="50%" bgcolor="#9933FF">
<asp:Label ID="Label370" runat="server" Text="My text></asp:Label>
</td>
</tr>
</table>
</asp:Panel>
</ItemTemplate>
It will "drift" for each row (no vertical alignment) despite no text being close to long enough to fill the 50% for each column. If we change to:
<ItemTemplate>
<asp:Panel ID="panelMyPanel" runat="server" Height="55px"
Width="600px">
<table align="left" cellpadding="2" cellspacing="2" class="style1">
<tr>
<td width="300px" bgcolor="#990099">
<asp:Label ID="Label370" runat="server" Text="My text></asp:Label>
</td>
<td width="300px" bgcolor="#9933FF">
<asp:Label ID="Label370" runat="server" Text="My text></asp:Label>
</td>
</tr>
</table>
</asp:Panel>
</ItemTemplate>
Shouldn't both work and produce the same result? We prefer to specify width in % instead of PX as that will work even if page skin or similar is changed in the future.