Hi,
I have a detailsview which shows large text. What i want is to show only the
beginning of the text in normal mode and the full text in edit mode.
Here the code:
Thanks
Eric
<asp:SqlDataSou rce ID="SqlDataSour ce1" runat="server"
ConnectionStrin g="<%$ ConnectionStrin gs:myconn %>"
SelectCommand=" SELECT .... FROM mytable"
UpdateCommand=" UPDATE ...." >
<UpdateParamete rs>
<asp:Paramete r Name="id" Type="Int32" />
....
</UpdateParameter s>
</asp:SqlDataSour ce>
<asp:DetailsVie w ID="DetailsView 1" runat="server" ... >
<Fields>
<asp:TemplateFi eld >
<ItemTemplate >
<asp:Label ID="Label1" runat="server" Text='<%# Bind("n1")
%>'></asp:Label>
</ItemTemplate>
<EditItemTempla te>
<asp:TextBox ID="TextBox1" TextMode="Multi Line" runat="server" Text='<%#
Bind("n1") %>' ></asp:TextBox>
</EditItemTemplat e>
</asp:TemplateFie ld>
....
I have a detailsview which shows large text. What i want is to show only the
beginning of the text in normal mode and the full text in edit mode.
Here the code:
Thanks
Eric
<asp:SqlDataSou rce ID="SqlDataSour ce1" runat="server"
ConnectionStrin g="<%$ ConnectionStrin gs:myconn %>"
SelectCommand=" SELECT .... FROM mytable"
UpdateCommand=" UPDATE ...." >
<UpdateParamete rs>
<asp:Paramete r Name="id" Type="Int32" />
....
</UpdateParameter s>
</asp:SqlDataSour ce>
<asp:DetailsVie w ID="DetailsView 1" runat="server" ... >
<Fields>
<asp:TemplateFi eld >
<ItemTemplate >
<asp:Label ID="Label1" runat="server" Text='<%# Bind("n1")
%>'></asp:Label>
</ItemTemplate>
<EditItemTempla te>
<asp:TextBox ID="TextBox1" TextMode="Multi Line" runat="server" Text='<%#
Bind("n1") %>' ></asp:TextBox>
</EditItemTemplat e>
</asp:TemplateFie ld>
....
Comment