Ejemplo n.º 1
0
    protected void AdminView_Command(object sender, CommandEventArgs e)
    {
        CloseAll();
        Admns.Attributes.Remove("style");
        Admns.Style.Add("display", "block");

        DropEmployees.DataSource     = Obj.GetDataSetByID("GetEmployeesName", Convert.ToInt32(e.CommandArgument));
        DropEmployees.DataTextField  = "EmpName";
        DropEmployees.DataValueField = "EmpID";
        DropEmployees.DataBind();
        DropEmployees.Items.Insert(0, "");

        LblSecID.Text = e.CommandArgument.ToString();
        FillManagers();
    }
Ejemplo n.º 2
0
    protected void SaveManger_Click1(object sender, EventArgs e)
    {
        SucE.Visible = false;
        SucD.Visible = false;
        RettE.Text   = "";
        var Res = Obj.ExecuteProcedure2ID("AssignSectionManager", Convert.ToInt32(DropEmployees.SelectedValue), Convert.ToInt32(LblSecID.Text));

        if (Res != 0)
        {
            DropEmployees.DataSource     = Obj.GetDataSetByID("GetEmployeesName", Convert.ToInt32(LblSecID.Text));
            DropEmployees.DataTextField  = "EmpName";
            DropEmployees.DataValueField = "EmpID";
            DropEmployees.DataBind();
            DropEmployees.Items.Insert(0, "");
            FillManagers();
            SucE.Visible = true;
        }
        else
        {
            RettE.Text = " خطأ فى التنفيذ";
        }
    }
Ejemplo n.º 3
0
    protected void DelManager_Click(object sender, ImageClickEventArgs e)
    {
        SucE.Visible = false;
        SucD.Visible = false;
        RettE.Text   = "";

        var Res = Obj.ExecuteProcedureID("DelManger", Convert.ToInt32(DMang.Value));

        if (Res == 1)
        {
            FillManagers();
            SucD.Visible                 = true;
            DropEmployees.DataSource     = Obj.GetDataSetByID("GetEmployeesName", Convert.ToInt32(LblSecID.Text));
            DropEmployees.DataTextField  = "EmpName";
            DropEmployees.DataValueField = "EmpID";
            DropEmployees.DataBind();
            DropEmployees.Items.Insert(0, "");
        }
        else
        {
            RettE.Text = " خطأ فى التنفيذ";
        }
    }