private bool DoEdit(int _id)
        {
            bool result = true;

            BLL.norulesbll    bll   = new BLL.norulesbll();
            Model.norulesinfo model = bll.GetModel(_id);

            model.Code                      = txtCode.Text.Trim();
            model.Car_Number                = ddlCar_Number.SelectedValue;
            model.Driver                    = new Model.car_driverinfo();
            model.Driver.Driver_Code        = ddlDriver_Code.SelectedValue;
            model.NoRules_Time              = txtNoRules_Time.Text;
            model.NoRules_Class             = new Model.norules_classinfo();
            model.NoRules_Class.NRules_Code = ddlNoRules_Class_Code.SelectedValue;
            model.Address                   = txtAddress.Text;
            string s = txtCost.Text;

            model.Cost     = decimal.Parse(s == "" ? "0" : s);
            s              = txtScore.Text;
            model.Score    = Convert.ToInt64(s == "" ? "0" : s);
            model.cContent = txtcContent.Text;

            if (!bll.Update(model))
            {
                result = false;
            }
            return(result);
        }
        private void ShowInfo(int _id)
        {
            BLL.norulesbll    bll   = new BLL.norulesbll();
            Model.norulesinfo model = bll.GetModel(_id);

            txtCode.Text = model.Code;
            ddlCar_Number.SelectedValue         = model.Car_Number;
            ddlDriver_Code.SelectedValue        = model.Driver.Driver_Code;
            txtNoRules_Time.Text                = model.NoRules_Time;
            ddlNoRules_Class_Code.SelectedValue = model.NoRules_Class.NRules_Code;
            txtAddress.Text  = model.Address;
            txtCost.Text     = model.Cost.ToString();
            txtScore.Text    = model.Score.ToString();
            txtcContent.Text = model.cContent;
        }