protected void DropDownList4_SelectedIndexChanged(object sender, EventArgs e)
    {
        if (Session["company_id"] != null)
        {
            company_id = Convert.ToInt32(Session["company_id"].ToString());
        }

        SqlConnection con = new SqlConnection(ConfigurationManager.AppSettings["connection"]);
        SqlCommand    cmd = new SqlCommand("Select * from subcategory where category_id='" + DropDownList4.SelectedItem.Value + "' and Com_Id='" + company_id + "'", con);

        con.Open();
        DataSet        ds = new DataSet();
        SqlDataAdapter da = new SqlDataAdapter(cmd);

        da.Fill(ds);


        DropDownList6.DataSource     = ds;
        DropDownList6.DataTextField  = "subcategoryname";
        DropDownList6.DataValueField = "subcategory_id";
        DropDownList6.DataBind();
        DropDownList6.Items.Insert(0, new ListItem("All", "0"));



        con.Close();
        ModalPopupExtender3.Show();
    }
 protected void Button11_Click(object sender, EventArgs e)
 {
     Session["Apoleies_ID_For_Update"] = "0";
     Session["New_Pass_Per"]           = "XXX";
     Label2.Text = "Δημιουργία Αίτησης Νέου  : ";
     ModalPopupExtender3.Show();
 }
        protected void btnStatement_Click(object sender, EventArgs e)
        {
            try
            {
                string eid   = Convert.ToString(Session["EID"]);
                string OCODE = ((SessionUser)Session["SessionUser"]).OCode;
                List <HRM_EmployeeStatement> employeeStatments = employeeSetupDal.GetStatementList(eid, OCODE);
                if (employeeStatments.Count > 0)
                {
                    foreach (HRM_EmployeeStatement aitem in employeeStatments)
                    {
                        txtbxNameOfRelative.Text = aitem.NameOfRelative;
                        txtbxEId.Text            = aitem.RelativeEID;
                        txtbxRelation.Text       = aitem.Relation;
                    }
                }


                //Button2.Visible = true;
                Button3.Visible = true;
                ModalPopupExtender3.Show();
            }
            catch (Exception)
            {
                throw;
            }
        }
示例#4
0
 protected void Button3_Click(object sender, EventArgs e)
 {
     Session["New_Apoleies_DT"] = "0";
     Session["Return_TO_Ap_FD"] = "0";
     // Response.Redirect("Apoleia.aspx");
     ModalPopupExtender3.Show();
 }
    protected void PayCompRolePayGrid_SelectedIndexChanged(object sender, EventArgs e)
    {
        foreach (GridViewRow row in PayCompRolePayGrid.Rows)
        {
            if (row.RowIndex == PayCompRolePayGrid.SelectedIndex)
            {
                row.BackColor = ColorTranslator.FromHtml("#A1DCF2");
                row.ToolTip   = string.Empty;

                //ViewState["PayCompId"] = (int)ManagePayComponentGrid.DataKeys[ManagePayComponentGrid.SelectedIndex].Value;

                //txtfrmDate.Enabled = true;
                //btnEditDate.Enabled = true;
                //txtDeclaredAmt.Enabled = true;

                ModalPopupExtender3.Show();
                EmployeePayCompPopUp.Visible = true;
            }
            else
            {
                row.BackColor = ColorTranslator.FromHtml("#FFFFFF");
                row.ToolTip   = "Click to select this row.";

                ModalPopupExtender3.Show();
                EmployeePayCompPopUp.Visible = true;
            }
        }
    }
        protected void ImageButton4_Click(object sender, ImageClickEventArgs e)
        {
            if (TextBox5.Text.Length > 10)
            {
                if ((int)Session["Lang_EN_GR"] == 0)
                {
                    Label2.Text = "Λανθασμένη Ημερομηνία Γεννήσεως, αποδεκτή μορφή HH/MM/EEEE π.χ. '15/01/1980'";
                }
                else
                {
                    Label2.Text = "Wrong Date of Birth, acceptable format dd/MM/yyyy e.g. '15/01/1980'";
                }

                ModalPopupExtender3.Show();
            }
            else
            {
                Reservations.Update();
                ABE_KINISI.Insert();
                Search_politi.DataBind();
                GridView1.DataBind();

                Response.Redirect("SCEND.aspx");
            }
        }
示例#7
0
        public void btn_edit_Click(object sender, EventArgs e)
        {
            LinkButton  lb  = (LinkButton)sender;
            GridViewRow row = (GridViewRow)lb.NamingContainer;

            if (row != null)
            {
                int index = row.RowIndex; //gets the row index selected

                using (GridViewRow row1 = (GridViewRow)((LinkButton)sender).Parent.Parent)
                {
                    txt_Editmasked.ReadOnly  = true;
                    txt_Editmasked.Text      = row1.Cells[0].Text;
                    txt_editcustname.Text    = row1.Cells[1].Text;
                    txt_editcustemail.Text   = row1.Cells[2].Text;
                    txt_editcustccemail.Text = row1.Cells[3].Text.Replace("&nbsp;", "");
                    SqlConnection con = new SqlConnection(constr);
                    SqlCommand    cmd = new SqlCommand("spGetPDFPass", con);
                    cmd.CommandType = CommandType.StoredProcedure;
                    cmd.Parameters.AddWithValue("@masked", txt_Editmasked.Text);
                    con.Open();
                    cmd.ExecuteNonQuery();
                    SqlDataReader dr = cmd.ExecuteReader();
                    dr.Read();
                    txt_editpdfpass.Text = dr["pdfpassword"].ToString();
                    dr.Close();
                    con.Close();
                    ModalPopupExtender3.Show();
                }
            }
        }
示例#8
0
 protected void GridNodalOfficerDetails_RowCommand(object sender, GridViewCommandEventArgs e)
 {
     try
     {
         if (e.CommandName == "NodalOfficerDetails")
         {
             //Determine the RowIndex of the Row whose Button was clicked.
             string          loginId = e.CommandArgument.ToString();
             DashBoardDataBL obje    = null;
             obje = new DashBoardDataBL();
             DataTable dt = obje.GetNodalOfficerNameBL("NodalOfficerDetails", loginId);
             lblName.Text        = dt.Rows[0]["N_Name"].ToString();
             lblMinistry.Text    = dt.Rows[0]["MinName"].ToString();
             lblDesignation.Text = dt.Rows[0]["DesignationName"].ToString();
             lblMobile.Text      = dt.Rows[0]["N_Mobile"].ToString();
             lblEmail.Text       = dt.Rows[0]["N_Email"].ToString();
             lbltelephone.Text   = dt.Rows[0]["N_Telephone"].ToString();
             lbladdress.Text     = dt.Rows[0]["N_Address1"].ToString() + " " + dt.Rows[0]["N_Address2"].ToString() + " " + dt.Rows[0]["N_Address3"].ToString();
             ModalPopupExtender3.Show();
         }
     }
     catch (Exception ex)
     {
         LogError(ex);
     }
 }
示例#9
0
        protected void ImageButton3_Click(object sender, ImageClickEventArgs e)
        {
            ArticuloId = null;
            ImageButton ImgB  = sender as ImageButton;
            GridViewRow gvRow = (GridViewRow)ImgB.NamingContainer;

            if (!_isRefresh)
            {
                ArticuloId = ControlArticulo.BuscarXId(Convert.ToInt32(gvRow.Cells[0].Text));
                if (ControlArticulo.ArtRepetidosEnElPedido(ListaArticulo, ArticuloId) == false)
                {
                    ModalPopupExtender3.Show();
                }
                else
                {
                    ScriptManager.RegisterStartupScript(this, GetType(), "Popup", "ArtIngresado();", true);
                    TxtBuscarNombre.Text = "";
                }
            }
            else
            {
                Limpiar();
                Response.Redirect("AgregarPedido.aspx");
            }
        }
        protected void ImageButton4_Click(object sender, ImageClickEventArgs e)
        {
            if (EpikCHB.Checked)
            {
                TextBox12.Text = "8";
                Reservations.Update();
                for (int i = 0; i < Convert.ToInt16(DropDownList1.SelectedValue); i++)
                {
                    Reservations.Insert();
                    ABE_KINISI.Insert();
                }

                Reservations.Delete();
                Response.Redirect("SCEND.aspx");
            }
            else
            {
                if ((int)Session["Lang_EN_GR"] == 0)
                {
                    Label2.Text = "Παρακαλώ επιλέξτε Προξενική Πράξη";
                }
                else
                {
                    Label2.Text = "Please choose a Consular Service";
                }
                Button8.Visible = false;
                ModalPopupExtender3.Show();
            }
        }
示例#11
0
        protected void ImgBtnAddCantidad_Click(object sender, ImageClickEventArgs e)
        {
            ImageButton ImgB  = sender as ImageButton;
            GridViewRow gvRow = (GridViewRow)ImgB.NamingContainer;

            Artid = Convert.ToInt32(gvRow.Cells[0].Text);
            ModalPopupExtender3.Show();
        }
示例#12
0
 private void ValidarModalSearch()
 {
     if (HiddenActivateModalSearch.Value == "1")
     {
         ModalPopupExtender3.Show();
     }
     else
     {
         ModalPopupExtender3.Hide();
     }
 }
示例#13
0
 protected void btnMItemSearch_Click(object sender, EventArgs e)
 {
     try
     {
         ModalPopupExtender3.Show();
         SearchItem();
     }
     catch (Exception ex)
     {
     }
 }
示例#14
0
 protected void imgbtnSearchItem_Click_Click(object sender, ImageClickEventArgs e)
 {
     try
     {
         ModalPopupExtender3.Show();
         SearchItem();
     }
     catch (Exception ex)
     {
     }
 }
示例#15
0
 protected void btnSearchClients_Click(object sender, EventArgs e)
 {
     try
     {
         ModalPopupExtender3.Show();
         HiddenActivateModalSearch.Value = "1";
     }
     catch (Exception ex)
     {
         UserMessage(ex.Message, "danger");
     }
 }
示例#16
0
 protected void lnkRevisedppr_Click(object sender, EventArgs e)
 {
     try
     {
         savetopdf("Revised");
         ModalPopupExtender3.Show();
     }
     catch (Exception ex)
     {
         LogError(ex);
     }
 }
示例#17
0
    protected void AssignRolePayMapBtn_Click(object sender, EventArgs e)
    {
        if (PayCompRolePayGrid.Rows.Count == 0)
        {
            ModalPopupExtender3.Show();
            EmployeePayCompPopUp.Visible = true;

            StringBuilder scriptMsg = new StringBuilder();
            scriptMsg.Append("alert('Pay Components is empty');");
            ScriptManager.RegisterStartupScript(Page, Page.GetType(), Guid.NewGuid().ToString(), scriptMsg.ToString(), true);
        }
    }
 protected void DropDownList10_SelectedIndexChanged(object sender, EventArgs e)
 {
     if (TextBox27.Text != "0")
     {
         ModalPopupExtender3.Show();
     }
     else
     {
         TextBox9.Text = DropDownList10.SelectedValue;
         Ypologos.DataBind();
     }
 }
示例#19
0
 protected void btnAddModal_Click(object sender, EventArgs e)
 {
     try
     {
         ClearTextSearchItem();
         ModalPopupExtender3.Show();
         SearchItem();
     }
     catch (Exception ex)
     {
     }
 }
示例#20
0
 protected void PprDocumentDownload(object sender, EventArgs e)
 {
     try
     {
         //saveToPDF(ViewState["PPRId"].ToString());
         savetopdf("Original");
         ModalPopupExtender3.Show();
     }
     catch (Exception ex)
     {
         LogError(ex);
     }
 }
示例#21
0
    protected void removeSelectedBtn_Click(object sender, EventArgs e)
    {
        txtDeclaredAmt.Text    = null;
        txtfrmDate.Text        = null;
        txtfrmDate.Enabled     = false;
        btnEditDate.Enabled    = false;
        txtDeclaredAmt.Enabled = false;
        ManagePayComponentGrid.SelectedIndex = -1;
        roleSearch.Text = "";

        GetPayComponent(string.Empty);

        ModalPopupExtender3.Show();
        EmployeePayCompPopUp.Visible = true;
    }
示例#22
0
    protected void lblTicketNumber_Click(object sender, EventArgs e)
    {
        eq.TKTID = Session["TKTID"].ToString();
        DataSet DSR = ObjDAL.GetGridRmkAll(eq.TKTID);

        if (DSR.Tables[0].Rows.Count > 0)
        {
            popGridview.DataSource = DSR;
            popGridview.DataBind();
            popGridview.Visible = true;
            popGridview.DataBind();
            ModalPopupExtender3.Show();
            UpdatePanel15.Update();
        }
    }
 protected void Page_Load(object sender, EventArgs e)
 {
     //  ModalPopupExtender3.Show();
     if (!IsPostBack)
     {
         if (Session["pagesearch"] != null)
         {
             ViewState["sortOrder"] = "";
             TextBox5.Text          = Session["pagesearch"].ToString();
             lbltext.Text           = " Search as: " + Session["pagesearch"].ToString();
             lbltext.Text           = "Page Search Result";
             filterproduct();
             ModalPopupExtender3.Show();
         }
     }
 }
示例#24
0
 protected void Button8_Click(object sender, EventArgs e)
 {
     Button12.Visible             = true;
     Button13.Visible             = false;
     TextBox15.Text               = ApptP_ID;
     DropDownList13.SelectedIndex = 0;
     DropDownList14.SelectedIndex = 0;
     DropDownList15.SelectedIndex = 0;
     DropDownList16.SelectedIndex = 88;
     TextBox16.Text               = "";
     TextBox17.Text               = "";
     TextBox18.Text               = "";
     TextBox20.Text               = "";
     TextBox23.Text               = "";
     ModalPopupExtender3.Show();
 }
示例#25
0
    protected void SearchRoleBtn_Click(object sender, EventArgs e)
    {
        //if (roleSearch.Text == "")
        //{
        //    ScriptManager.RegisterStartupScript(Page, Page.GetType(), Guid.NewGuid().ToString(), "alert('Enter Pay Component Name');", true);
        //    ModalPopupExtender3.Show();
        //    EmployeePayCompPopUp.Visible = true;
        //}
        //else
        //{
        GetPayComponent(roleSearch.Text);

        ModalPopupExtender3.Show();
        EmployeePayCompPopUp.Visible = true;
        //}
    }
示例#26
0
 protected void BtnBuscarCod_Click(object sender, EventArgs e)
 {
     AuxTotal             = 0;
     Session["Auxdouble"] = AuxTotal;
     ArticuloId           = null;
     if (IsValid)
     {
         if (!_isRefresh)
         {
             if (RadioButtonBuscarART.SelectedValue == "cod")
             {
                 ArticuloId = ControlArticulo.BuscarXIdActivo(Convert.ToInt32(TxtBuscarCod.Text.ToLower()));
                 if (ControlArticulo.ArtRepetidosEnElPedido(ListaArticulo, ArticuloId) == false)
                 {
                     if (ArticuloId != null)
                     {
                         if (!_isRefresh)
                         {
                             ModalPopupExtender3.Show();
                         }
                         else
                         {
                             Limpiar();
                             Response.Redirect("AgregarPedido.aspx");
                         }
                     }
                     else
                     {
                         ScriptManager.RegisterStartupScript(this, GetType(), "Popup", "erroralertart();", true);
                     }
                 }
                 else
                 {
                     ScriptManager.RegisterStartupScript(this, GetType(), "Popup", "ArtIngresado();", true);
                     TxtBuscarCod.Text = "";
                 }
             }
         }
         else
         {
             Limpiar();
             TextCant.Text    = "1";
             LblError.Visible = false;
             Response.Redirect("AgregarPedido.aspx");
         }
     }
 }
示例#27
0
        protected void grdFormPreventiva_RowCommand(object sender, GridViewCommandEventArgs e)
        {
            if (e.CommandName == "Select")
            {

                int linha = int.Parse(e.CommandArgument.ToString());
                int CoPreventiva = int.Parse(grdFormPreventiva.DataKeys[linha]["cmpCoPreventiva"].ToString());
                int CoObraGrupoLista = int.Parse(grdFormPreventiva.DataKeys[linha]["cmpCoObraGrupoLista"].ToString());

                this.Session["cmpCoPreventiva"] = int.Parse(grdFormPreventiva.DataKeys[linha]["cmpCoPreventiva"].ToString());
                this.Session["cmpCoObraGrupoLista"] = int.Parse(grdFormPreventiva.DataKeys[linha]["cmpCoObraGrupoLista"].ToString());

                //DataTable dtEquipamentoObra = tblEquipamentoObra.RetornarEquipamentoObra(Global.GetConnection(), CoObraGrupoLista);
                DataTable dtEquipamentoObra =PesquisaEquipamento();
                dgvEquipamento.DataSource = dtEquipamentoObra;
                dgvEquipamento.DataBind();
                this.ModalPopupExtender1.Show();
            }
            if (e.CommandName == "Visualizar")
            {
                LinkButton lk = (LinkButton)e.CommandSource;
                string[] Valores = lk.Text.Split('/');
                //Response.Write("<script>window.open('webPRE_EditarPreventiva.aspx?idPreventivaAgenda=" + lk.Text + "','_blank');</script>");
                ListCampos ls = new ListCampos();
                ListCampo lc = new ListCampo();
                lc.NomeCampo = "[cmpCoPreventiva]";
                lc.TipoCampo = TipoCampo.Numero;
                lc.ValorCampo = Valores[0];
                ls.Add(lc);

                lc = new ListCampo();
                lc.NomeCampo = "[cmpCoGrupoAtividade]";
                lc.TipoCampo = TipoCampo.Numero;
                lc.ValorCampo = Valores[1];
                ls.Add(lc);

                lblPreventiva.Text = "Codigo Preventiva / Codigo Grupo Atividade :" + Valores[0] + "/" + Valores[1];
                DataTable dtPreventiva = tblPreventiva.RetornaDados(Global.GetConnection(), ls);
                grdPreventiva.DataSource = dtPreventiva;
                grdPreventiva.DataBind();
                ModalPopupExtender3.Show();

            }
        }
示例#28
0
   public void btnCreateGroup_Click(object sender, EventArgs e)
   {
       string message;
       string groupName = MyUtilities.clean(AddGroupName.Text);
       groupName = groupName.Trim();
       if (groupName == "")
       {
           //ShowErrorMessage("No group name entered.  Please try again.");  
           return;
       }

      

       int successCreate = groupManagement.add_new_group(groupName, username);
       if (successCreate == 0)
       {
           message = "Group name is already in use. Please choose a new group name.";
           logFiles.ErrorMessageLog(message);
           ShowErrorMessage(message);
           
          ModalPopupExtender3.Show();
           return;
       }
       if (successCreate == -1)
       {
           message = "Couldn't find added Group name TIMING!!!.";
           logFiles.ErrorMessageLog(message);
           ShowErrorMessage(message);
           
           return;
       }

       CurrentGroupName = groupName;
       ModalPopupExtender3.Hide();
       DropDownList2Bind();
       ModalPopupExtender3.Hide();

       //ShowErrorMessage("added group " + groupName);
       message = "User group " + groupName + " created.";
       MailInfo.SendMail(message, MailInfo.GROUP_CREATED);

       SetUserGridData();
  
   }
    protected void removeSelectedBtn_Click(object sender, EventArgs e)
    {
        try
        {
            if (PayCompRolePayGrid.SelectedDataKey != null)
            {
                int roleId = Convert.ToInt32(ManagePayRoleID.Value);

                int payCompId = Convert.ToInt32(PayCompRolePayGrid.SelectedDataKey.Value);

                BusinessLogic bL = new BusinessLogic(sDataSource);

                bL.DeleteRolePayComp(payCompId, roleId);

                txtDeclaredAmt.Text              = null;
                txtfrmDate.Text                  = null;
                txtfrmDate.Enabled               = false;
                btnEditDate.Enabled              = false;
                txtDeclaredAmt.Enabled           = false;
                PayCompRolePayGrid.SelectedIndex = -1;
                roleSearch.Text                  = "";

                GetPayComponent(string.Empty);

                GetRolePayComponent(roleId);

                ModalPopupExtender3.Show();
                EmployeePayCompPopUp.Visible = true;
            }
            else
            {
                ModalPopupExtender3.Show();
                EmployeePayCompPopUp.Visible = true;
                StringBuilder scriptMsg = new StringBuilder();
                scriptMsg.Append("alert('Please select paycomponent');");
                ScriptManager.RegisterStartupScript(Page, Page.GetType(), Guid.NewGuid().ToString(), scriptMsg.ToString(), true);
            }
        }
        catch (Exception ex)
        {
            ScriptManager.RegisterStartupScript(Page, Page.GetType(), Guid.NewGuid().ToString(), "alert(Failed :" + ex.Message.ToString() + "');", true);
        }
    }
示例#30
0
    protected void GrdEmp_RowCommand(object sender, GridViewCommandEventArgs e)
    {
        try
        {
            if (e.CommandName == "ManagePay")
            {
                string EmpName = string.Empty;
                int    EmpId   = 0;

                //FormViewManageLeave.Visible = true;
                //FormViewManageLeave.ChangeMode(FormViewMode.Insert);

                string[] args = e.CommandArgument.ToString().Split(new char[] { ':' });
                if (args.Length == 2)
                {
                    EmpName = args[0];

                    EmpId = Convert.ToInt32(args[1]);
                }

                GetPayComponent(string.Empty);

                GetEmpPayComponent(EmpId);

                txtManagePayCompRoleName.Text = EmpName;
                ManagePayRoleID.Value         = EmpId.ToString();

                txtfrmDate.Enabled     = false;
                btnEditDate.Enabled    = false;
                txtDeclaredAmt.Enabled = false;

                txtfrmDate.Text     = null;
                txtDeclaredAmt.Text = null;

                ModalPopupExtender3.Show();
                EmployeePayCompPopUp.Visible = true;
            }
        }
        catch (Exception ex)
        {
            TroyLiteExceptionManager.HandleException(ex);
        }
    }