Tuesday, 24 March 2015

How to change the modes of formview in asp.net C#?

The Edit mode provides us the updation methods:-

protected void Calendar1_SelectionChanged(object sender, EventArgs e)
    {
        FormView1.ChangeMode(FormViewMode.Edit);
    }

The Insert mode provides us the addition of new record:-

    protected void butAddNew_Click(object sender, EventArgs e)
    {
        FormView1.ChangeMode(FormViewMode.Insert);
    }

No comments:

Post a Comment