TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Meer Ahmed
NA
4
1.6k
Losing ViewState in Dynamic Controls adding.
Mar 2 2015 6:33 AM
I am working with Dynamic/Custom control,
my Controls contain an accordion, inside this accordion i have Gridview, The Gridview has events
Edit, Update.
When i Edit a Row and change a column value an press update, i did not get new column value in Updating event. I get old value of that column.
my Code is here.
<asp:TemplateField HeaderText="Order" HeaderStyle-ForeColor="White" HeaderStyle-BorderColor="Black">
<EditItemTemplate>
<center>
<asp:TextBox ID="txt" CssClass="Order_txt" runat="server" Text='<%# bind("value") %>'></asp:TextBox></center>
</EditItemTemplate>
<ItemTemplate>
<asp:Label ID="lbl" runat="server" Text='<%# bind("value") %>'></asp:Label>
</ItemTemplate>
<ItemStyle Width="90px" />
</asp:TemplateField>
In Code behind on GridView_Rowupdating event.
Dim valueAs String = CType(GV_Parameter.Rows(RowIndex).FindControl("txt"), System.Web.UI.WebControls.TextBox).Text
i get old value as i enter new value in text box.
Reply
Answers (
0
)
How to extract images from pdf and save into folder in C# ?
UserControl