using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class EditLog : System.Web.UI.Page
{
    
    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void SqlDataSource2_Selecting(object sender, SqlDataSourceSelectingEventArgs e)
    {
        e.Command.Parameters["@bloger_name"].Value = this.User.Identity.Name;
    }
    protected void SqlDataSource1_Selecting(object sender, SqlDataSourceSelectingEventArgs e)
    {
        e.Command.Parameters["@log_id"].Value = Request["log_id"];
    }
    protected void SqlDataSource1_Inserting(object sender, SqlDataSourceCommandEventArgs e)
    {

    }
    protected void FormView1_DataBound(object sender, EventArgs e)
    {
        this.FormView1.ChangeMode(FormViewMode.Edit);
    }
    protected void SqlDataSource1_Updating(object sender, SqlDataSourceCommandEventArgs e)
    {
        if (IsPostBack)
        {
            int category_id = int.Parse(((DropDownList)this.FormView1.FindControl("DropDownList1")).SelectedValue);
            e.Command.Parameters["@category_id"].Value = category_id;
        }
    }
}
