Rad1
asked on
Gridview with added Templates and TextBox does not display text
Hi,
I have a Gridview with added Templates, I have TextBoxs in the Templates.
(See code below)
The problem:
One of the textboxes display data in it as supposed to, but the second textbox only displays a one line in it.
What make it do that????
Thank you!!!
I have a Gridview with added Templates, I have TextBoxs in the Templates.
(See code below)
The problem:
One of the textboxes display data in it as supposed to, but the second textbox only displays a one line in it.
What make it do that????
Thank you!!!
<asp:TemplateField HeaderText="Comments" SortExpression="Comments">
<HeaderStyle ForeColor="White" Font-Names="Times New Roman" Font-Size="Small" />
<EditItemTemplate>
<asp:TextBox ID="txtcomments" runat="server" CssClass="LongUrlLabel "
Height="100px" ontextchanged="txtDescription_TextChanged"
Text='<%# Bind("Comments") %>' TextMode="MultiLine" Width="300px"></asp:TextBox>
</EditItemTemplate>
<ItemTemplate>
<asp:Label ID="Label6" runat="server" Text='<%# Bind("Comments") %>'
Width="150px" Height="16px" CssClass="LongUrlLabel"></asp:Label>
</ItemTemplate>
<ControlStyle Width="250px" />
</asp:TemplateField>
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Its strange!!!
I have two pages with the same Gridview. On the first one it works just fine (display data or text fully), but on the other page the Gridview textboxes do not work (only display a one line).
I have two pages with the same Gridview. On the first one it works just fine (display data or text fully), but on the other page the Gridview textboxes do not work (only display a one line).
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Alan,
I found out that I was using
.LongUrlLabel { overflow:hidden; } which was causing the rest of the text to display.
But, the second column was display the whole text correctly?????
I found out that I was using
.LongUrlLabel { overflow:hidden; } which was causing the rest of the text to display.
But, the second column was display the whole text correctly?????
ASKER
Thank you Alan!!!
ASKER
Both textboxes are textboxes
Both are in different itemtemplate
Both are multiline