ProgrammingAnything related to coding, programming c, c++, vc++, c#, java, delphi, Visual Basic
The thread "example of editing in DataGrid and Default Paging" has not received any replies for a month. It has been automatically closed as a result. You may start a new thread on the topic if the information in this thread is not sufficient.
This is an example of editing in DataGrid and Default Paging
To view links or images in this forum your post count must be 1 or greater. You currently have 0 posts.
Html Design Code : -
<asp To view links or images in this forum your post count must be 1 or greater. You currently have 0 posts. ataGrid id="DataGrid1" DataKeyField="id" runat="server" Height="224px" AutoGenerateColumns="False" PageSize="5" AllowPaging="True">
<Columns>
<asp:BoundColumn Visible="False" DataField="id"
HeaderText="Category Id"></asp:BoundColumn>
<asp:TemplateColumn HeaderText="Category">
<ItemTemplate>
<asp:Label id=lblName text='<%# DataBinder.Eval(Container.DataItem,"name")%>' Runat="server">
</asp:Label>
</ItemTemplate>
<EditItemTemplate>
<asp:TextBox id=txtEdit Runat="server" Text='<%# DataBinder.Eval(Container.DataItem,"name")%>'>
</asp:TextBox>
</EditItemTemplate>
</asp:TemplateColumn>
<asp:EditCommandColumn ButtonType="LinkButton" UpdateText="Update" HeaderText="Edit" CancelText="Cancel"
EditText="Edit"></asp:EditCommandColumn>
</Columns>
</asp To view links or images in this forum your post count must be 1 or greater. You currently have 0 posts. ataGrid>
Code (EditInDataGrid.aspx.cs) :
private void Page_Load(object sender, System.EventArgs e)
{
// Put user code to initialize the page here
if(!IsPostBack)
{
To view links or images in signatures your post count must be 0 or greater. You currently have 0 posts.
The thread "example of editing in DataGrid and Default Paging" has not received any replies for a month. It has been automatically closed as a result. You may start a new thread on the topic if the information in this thread is not sufficient.