Пример #1
0
    protected void TxtCRAccNo_TextChanged(object sender, EventArgs e)
    {
        try
        {
            string AT = "";
            // AT = BD.GetStage1(TxtAccno.Text, Session["BRCD"].ToString(), ViewState["Flag"].ToString());
            AT = BD.Getstage1(TxtCRAccNo.Text, Session["BRCD"].ToString(), TxtCRPType.Text);
            if (AT != "1003")
            {
                lblMessage.Text = "Sorry Customer not Authorise.........!!";
                ModalPopup.Show(this.Page);
                ClearText();
                TxtPtype.Focus();
            }
            else
            {
                int RC = LI.CheckAccount(TxtCRAccNo.Text, TxtCRPType.Text, Session["BRCD"].ToString());

                if (RC < 0)
                {
                    TxtCRAccNo.Focus();
                    WebMsgBox.Show("Please Enter valide Account Number Account Not Exist..........!!", this.Page);
                    return;
                }
                ViewState["CRCustNo"] = RC;
                TxtCRACName.Text      = AO.Getcustname(RC.ToString());
                TxtChequeNo.Focus();
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
Пример #2
0
 public void ClosePopup(ModalPopup popup)
 {
     popup.Clear();
     inactivePopups.Add(popup.gameObject);
     activePopups.Remove(popup.gameObject);
     popup.gameObject.SetActive(false);
 }
    protected void btnsubmit_Click(object sender, EventArgs e)
    {
        try
        {
            int result = clsa.SubmitWchangepwd(encrypt(txtnewpwd.Text), txtlogincode.Text, encrypt(txtoldpwd.Text), Session["BRCD"].ToString(), ddlUname.SelectedValue.ToString());

            if (result > 0)
            {
                ClearField();
                lblMessage.Text = "Password Change successfully done....!!";
                ModalPopup.Show(this.Page);
                FL = "Insert";//Dhanya Shetty
                string Res = CLM.LOGDETAILS(FL, Session["BRCD"].ToString(), Session["MID"].ToString(), "Password_Submit _" + Session["LOGINCODE"].ToString() + "", "00", Session["MID"].ToString());
            }
            else if (result == 0)
            {
                lblMessage.Text = "Invalid Old Password....!!";
                ModalPopup.Show(this.Page);
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
    protected void btnsuspend_Click(object sender, EventArgs e)
    {
        string[] id = ViewState["id"].ToString().Split('_');

        if (Convert.ToDouble(id[0].ToString()) > 0)
        {
            int cnt = 0;
            if (Session["UGRP"].ToString() == "1" || Session["UGRP"].ToString() == "2" || Session["UGRP"].ToString() == "3")
            {
                cnt = clsa.Suspendusermaster(ViewState["id"].ToString(), Session["MID"].ToString());
                if (cnt > 0)
                {
                    BindGrid();
                    clear();
                    lblMessage.Text = "User Deleted Successfully...!";
                    ModalPopup.Show(this.Page);
                    FL = "Insert";//Dhanya Shetty
                    string Res = CLM.LOGDETAILS(FL, Session["BRCD"].ToString(), Session["MID"].ToString(), "User_Deleted _" + Session["LOGINCODE"].ToString() + "", "00", Session["MID"].ToString());
                }
            }
            else
            {
                lblMessage.Text = "Only Admin or Manager User can Delete User Details...!";
                ModalPopup.Show(this.Page);
            }
        }
    }
 protected void TxtAccHName_TextChanged(object sender, EventArgs e)
 {
     try
     {
         string   CUNAME  = TxtAccHName.Text;
         string[] custnob = CUNAME.Split('_');
         if (custnob.Length > 1)
         {
             TxtAccHName.Text = custnob[0].ToString();
             TxtAccno.Text    = (string.IsNullOrEmpty(custnob[1].ToString()) ? "" : custnob[1].ToString());
             //--Abhishek
             string RES = AST.GetAccStatus(TxtBRCD.Text, TxtAccno.Text, TxtAccType.Text);
         }
         else
         {
             lblMessage.Text = "Invalid Account Number.........!!";
             ModalPopup.Show(this.Page);
             return;
         }
         if (TxtAccHName.Text != "")
         {
         }
     }
     catch (Exception Ex)
     {
         ExceptionLogging.SendErrorToText(Ex);
         //Response.Redirect("FrmLogin.aspx", true);
     }
 }
Пример #6
0
    protected void TxtAccno_TextChanged(object sender, EventArgs e)
    {
        try
        {
            if (TxtBRCD.Text != "")
            {
                string AT = "";
                // AT = BD.GetStage1(TxtAccno.Text, Session["BRCD"].ToString(), ViewState["Flag"].ToString());
                AT = BD.Getstage1(TxtAccno.Text, TxtBRCD.Text, TxtAccType.Text);
                if (AT != "1003")
                {
                    lblMessage.Text = "Sorry Customer not Authorise.........!!";
                    ModalPopup.Show(this.Page);
                    TxtAccHName.Text = "";
                    TxtAccno.Text    = "";
                    TxtAccno.Focus();
                }
                else
                {
                    DataTable DT = new DataTable();
                    DT = AST.GetCustName(TxtAccType.Text, TxtAccno.Text, TxtBRCD.Text);
                    if (DT.Rows.Count > 0)
                    {
                        string[] TD = TxtTDate.Text.Split('/');
                        TxtAccHName.Text = DT.Rows[0]["CustName"].ToString();
                        TxtOPDT.Text     = Convert.ToDateTime(DT.Rows[0]["OPENINGDATE"]).ToString("dd/MM/yyyy");
                        //--Abhishek
                        string RES = AST.GetAccStatus(TxtBRCD.Text, TxtAccno.Text, TxtAccType.Text);
                        if (RES == "1")
                        {
                            TxtACStatus.Text = "Active";
                        }
                        else if (RES == "9")
                        {
                            TxtACStatus.Text = "Suit File";
                        }
                        else
                        {
                            TxtACStatus.Text = "Deactive";
                        }
                        TxtClearBal.Text   = OC.GetOpenClose("CLOSING", TD[2].ToString(), TD[1].ToString(), TxtAccType.Text, TxtAccno.Text, Session["BRCD"].ToString(), Session["EntryDate"].ToString(), ViewState["GL"].ToString()).ToString();
                        TxtUnClearBal.Text = OC.GetOpenClose("Unclear", TD[2].ToString(), TD[1].ToString(), TxtAccType.Text, TxtAccno.Text, Session["BRCD"].ToString(), Session["EntryDate"].ToString(), ViewState["GL"].ToString()).ToString();
                    }

                    TxtFDate.Focus();
                }
            }
            else
            {
                WebMsgBox.Show("Enter Branch Code First....!", this.Page);
                TxtAccno.Text = "";
                TxtBRCD.Focus();
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
            //Response.Redirect("FrmLogin.aspx", true);
        }
    }
Пример #7
0
    protected void TxtAmount_TextChanged(object sender, EventArgs e)
    {
        try
        {
            if (DdlCRDR.SelectedValue == "2")
            {
                if (ddlPMTMode.SelectedValue != "3")
                {
                    double BAL    = Convert.ToDouble(TxtBalance.Text.Trim().ToString() == "" ? "0" : TxtBalance.Text.Trim().ToString());
                    double curbal = Convert.ToDouble(TxtAmount.Text.Trim().ToString() == "" ? "0" : TxtAmount.Text.Trim().ToString());

                    if ((Convert.ToInt32(ViewState["GlCode"].ToString()) < 100) && Convert.ToInt32(ViewState["GlCode"].ToString()) != 3)
                    {
                        if (curbal > BAL)
                        {
                            lblMessage.Text = "Insufficient Account Balance...!!";
                            TxtAmount.Text  = "";
                            TxtAmount.Focus();
                            ModalPopup.Show(this.Page);
                            return;
                        }
                    }
                }
            }

            Submit.Focus();
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
Пример #8
0
    protected void txtPeriod_TextChanged(object sender, EventArgs e)
    {
        try
        {
            if (txtDepAmt.Text == "")
            {
                lblMessage.Text = "First Enter Amount...!!";
                ModalPopup.Show(this.Page);
                txtDepAmt.Focus();
                return;
            }

            if (txtPeriod.Text == "")
            {
                return;
            }
            if (ddlDuration.SelectedValue == "M")
            {
                txtDueDate.Text = conn.AddMonthDay(txtDepDate.Text, txtPeriod.Text, "M").Replace("12:00:00", "");
                txtDueDate.Text = conn.AddMonthDay(txtDepDate.Text, txtPeriod.Text, "M").Replace("12:00:00", "");
            }
            else if (ddlDuration.SelectedValue == "D")
            {
                txtDueDate.Text = conn.AddMonthDay(txtDepDate.Text, txtPeriod.Text, "D").Replace("12:00:00", "");
                txtDueDate.Text = conn.AddMonthDay(txtDepDate.Text, txtPeriod.Text, "D").Replace("12:00:00", "");
            }
            txtIntRate.Focus();
        }
        catch (Exception ex)
        {
            ExceptionLogging.SendErrorToText(ex);
        }
    }
Пример #9
0
    protected void btnCreate_Click(object sender, EventArgs e)
    {
        try
        {
            if (TxtClBal.Text == "0")
            {
                WebMsgBox.Show("Restricted..!! Closing balance is 0..!", this.Page);
                return;
            }
            else
            {  //Session["BRCD"].ToString() ADDED BY ASHOK DUE TO HARD CODE BRCD
                resultint = IAM.AddInvestment(Session["BRCD"].ToString(), txtBankNo.Text.Trim().ToString(), txtBankName.Text.Trim().ToString(), "0", txtBranchName.Text.Trim().ToString(), txtReceiptNo.Text.Trim().ToString(), txtReceiptName.Text.Trim().ToString(), txtBResNo.Text.Trim().ToString(), txtBMeetDate.Text.Trim().ToString(), txtOpenDate.Text.Trim().ToString(), Session["EntryDate"].ToString(), Session["MID"].ToString(), txtPrinAccNo.Text, txtPrinProdCode.Text, "0", txtIntProdCode.Text, ddlInvestment.SelectedValue, txtAC.Text, txtBank1.Text, txtPrinAccName.Text, txtPeriod.Text.Trim().ToString(), Convert.ToDouble(txtIntRate.Text.Trim().ToString()), Convert.ToDouble(txtDepAmt.Text.Trim().ToString()), Convert.ToDouble(txtIntAmt.Text.Trim().ToString()), Convert.ToDouble(txtMaturityAmt.Text.Trim().ToString()), ddlIntrestPay.SelectedValue.ToString(), ddlDuration.SelectedValue.ToString(), txtDueDate.Text.Trim().ToString(), "1");

                if (resultint > 0)
                {
                    lblMessage.Text = "Record Added Successfully...!!";
                    ModalPopup.Show(this.Page);
                    bindgrid();
                    FL = "Insert";//Dhanya Shetty
                    string Res = CLM.LOGDETAILS(FL, Session["BRCD"].ToString(), Session["MID"].ToString(), "InvstDataEntry_Add _" + Session["LOGINCODE"].ToString() + "", "00", Session["MID"].ToString());
                    ClearData();
                    ClearAllData();
                }
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
Пример #10
0
    protected void TxtPayAccName_TextChanged(object sender, EventArgs e)
    {
        try
        {
            string[] custnob = TxtPayAccName.Text.ToString().Split('_');
            if (custnob.Length > 1)
            {
                sResult = SR.GetAccStatus(txtPayBrCode.Text.ToString(), txtPayProdType.Text.ToString(), (string.IsNullOrEmpty(custnob[1].ToString()) ? "" : custnob[1].ToString()));
                if (sResult != "3")
                {
                    TxtPayAccName.Text = custnob[0].ToString();
                    TxtPayAccNo.Text   = (string.IsNullOrEmpty(custnob[1].ToString()) ? "" : custnob[1].ToString());

                    txtNarration.Focus();
                }
                else
                {
                    TxtPayAccNo.Text   = "";
                    TxtPayAccName.Text = "";
                    lblMessage.Text    = "Account is closed...!!";
                    ModalPopup.Show(this.Page);
                    TxtPayAccNo.Focus();
                }
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
Пример #11
0
 protected void TxtWRAccName_TextChanged(object sender, EventArgs e)
 {
     try
     {
         string   CUNAME  = TxtWRAccName.Text;
         string[] custnob = CUNAME.Split('_');
         if (custnob.Length > 1)
         {
             TxtWRAccName.Text   = custnob[0].ToString();
             TxtWRAccNo.Text     = (string.IsNullOrEmpty(custnob[1].ToString()) ? "" : custnob[1].ToString());
             ViewState["CUSTNO"] = custnob[2].ToString();
             string[] TD = Session["EntryDate"].ToString().Split('/');
             TxtBalance.Text = OC.GetOpenClose("CLOSING", TD[2].ToString(), TD[1].ToString(), TxtWRPRCD.Text, TxtWRAccNo.Text, Session["BRCD"].ToString(), Session["EntryDate"].ToString(), ViewState["DRGL"].ToString()).ToString();
             //txtnaration1.Focus();
         }
         else
         {
             lblMessage.Text = "Invalid Account Number.........!!";
             ModalPopup.Show(this.Page);
             return;
         }
     }
     catch (Exception Ex)
     {
         ExceptionLogging.SendErrorToText(Ex);
         //Response.Redirect("FrmLogin.aspx", true);
     }
 }
Пример #12
0
    protected void TxtPayAccNo_TextChanged(object sender, EventArgs e)
    {
        try
        {
            sResult = SR.GetAccStatus(txtPayBrCode.Text.ToString(), txtPayProdType.Text.ToString(), TxtPayAccNo.Text.ToString());
            if (sResult != "3")
            {
                DataTable DT = new DataTable();
                DT = SR.GetCustName(txtPayProdType.Text, TxtPayAccNo.Text, txtPayBrCode.Text.Trim().ToString());
                if (DT.Rows.Count > 0)
                {
                    string[] CustName = DT.Rows[0]["CustName"].ToString().Split('_');
                    TxtPayAccName.Text = CustName[0].ToString();

                    txtNarration.Focus();
                }
            }
            else
            {
                TxtPayAccNo.Text   = "";
                TxtPayAccName.Text = "";
                lblMessage.Text    = "Account is closed...!!";
                ModalPopup.Show(this.Page);
                TxtPayAccNo.Focus();
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
    protected void lnkDens_Click(object sender, EventArgs e)
    {
        try
        {
            LinkButton objlink = (LinkButton)sender;
            string[]   dens    = objlink.CommandArgument.ToString().Split('_');
            Session["densset"]   = dens[0].ToString();
            Session["densamt"]   = dens[1].ToString();
            Session["denssubgl"] = dens[2].ToString();
            Session["densact"]   = dens[3].ToString();

            sResult = VD.CheckDenom(Session["BRCD"].ToString(), Session["densset"].ToString(), Session["EntryDate"].ToString());
            if (sResult == null)
            {
                string redirectURL = "FrmCashDenom.aspx";
                ScriptManager.RegisterStartupScript(Page, Page.GetType(), "popup", "window.open('" + redirectURL + "','_blank')", true);
            }
            else
            {
                lblMessage.Text = "Already Cash Denominations..!!";
                ModalPopup.Show(this.Page);
                return;
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
    protected void txtSetNo_TextChanged(object sender, EventArgs e)
    {
        try
        {
            if (Convert.ToInt32(txtSetNo.Text.Trim().ToString() == "" ? "0" : txtSetNo.Text.Trim().ToString()) > 0)
            {
                sResult = VD.CheckCashSet(Session["BRCD"].ToString(), txtEntryDate.Text.ToString(), txtSetNo.Text.Trim().ToString());

                if ((sResult != null && sResult == "3") || (sResult != null && sResult == "4"))
                {
                    btnSubmit.Focus();
                }
                else
                {
                    txtSetNo.Text = "";
                    txtSetNo.Focus();
                    lblMessage.Text = "Voucher is not of type-cash...!!";
                    ModalPopup.Show(this.Page);
                    return;
                }
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
    public void BindGrid()
    {
        try
        {
            int RS = 0;
            RS = DC.BrHandBetweenDate(GrdBranchH, Session["BRCD"].ToString(), txtFDate.Text.Trim().ToString(), txtTDate.Text.Trim().ToString(), Session["LOGINCODE"].ToString(), Session["MID"].ToString());

            if (ViewState["Flag"].ToString() == "DClose")
            {
                if (RS == 0)
                {
                    Btn_DayClose.Visible = true;
                    Btn_Handover.Visible = false;
                }
            }
            else if (ViewState["Flag"].ToString() == "BHand")
            {
                if (RS == 0)
                {
                    FL = "Insert";
                    string Res = CLM.LOGDETAILS(FL, Session["BRCD"].ToString(), Session["MID"].ToString(), "Branch_HandOver _" + Session["LOGINCODE"].ToString() + "", "00", Session["MID"].ToString());
                    lblMessage.Text = "Branch Handover Successfully...!!";
                    ModalPopup.Show(this.Page);
                    return;
                }
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
Пример #16
0
    protected void txtIntProdCode_TextChanged(object sender, EventArgs e)
    {
        try
        {
            string AC1;
            AC1 = ICR.Getaccno(txtIntProdCode.Text, Session["BRCD"].ToString());

            if (AC1 != null)
            {
                string[] AC = AC1.Split('_');;
                ViewState["IntGlCode"] = AC[0].ToString();
                txtIntProdName.Text    = AC[1].ToString();
            }
            else
            {
                txtIntProdCode.Text = "";
                txtIntProdName.Text = "";
                lblMessage.Text     = "Enter valid Product code...!!";
                ModalPopup.Show(this.Page);

                txtIntProdCode.Focus();
                return;
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
 protected void txtBrCode_TextChanged(object sender, EventArgs e)
 {
     try
     {
         if (txtBrCode.Text != "")
         {
             string bname = DC.GetBranchName(txtBrCode.Text.Trim().ToString());
             if (bname != null)
             {
                 txtBrName.Text = bname;
                 txtFDate.Focus();
             }
             else
             {
                 lblMessage.Text = "Enter valid Branch Code...!!";
                 ModalPopup.Show(this.Page);
                 return;
             }
         }
         else
         {
             lblMessage.Text = "Enter Branch Code...!!";
             ModalPopup.Show(this.Page);
             txtBrCode.Focus();
             return;
         }
     }
     catch (Exception Ex)
     {
         ExceptionLogging.SendErrorToText(Ex);
     }
 }
Пример #18
0
    protected void PreviewPhoto_Click(object sender, EventArgs e)
    {
        string id = Txtcustno.Text;

        Image1.Visible = id != "0";
        if (id != "0")
        {
            pic = GetData("SELECT photo Data FROM avs1011 WHERE CUSTNO = " + id + " AND photo_type = '" + ddlDocType.SelectedValue.ToString() + "' ");
            if (pic.Rows.Count > 0)
            {
                byte[] bytes        = (byte[])pic.Rows[0]["Data"];
                string base64String = Convert.ToBase64String(bytes, 0, bytes.Length);
                Image1.ImageUrl = "data:image/tif;base64," + base64String;
                //imgPopup.ImageUrl = "data:image/tif;base64," + base64String;

                lblMessage.ForeColor = System.Drawing.Color.Green;
                lblMessage.Text      = "File Successfully Viewed";
                ModalPopup.Show(this.Page);
                Txtcustname.Text = "";
                Txtcustno.Text   = "";
            }
            else
            {
                lblMessage.ForeColor = System.Drawing.Color.Red;
                lblMessage.Text      = "No Image for that customer !!!!";
                ModalPopup.Show(this.Page);
            }
        }
    }
Пример #19
0
 protected void SetData(string FL)
 {
     try
     {
         DT = CH.GetIWOWCharges(FL);
         if (DT.Rows.Count > 0)
         {
             //--DESCRIPTION	CHARGES	PLACC	ST_SUBGL	LASTAPPLY
             TxtLastApplyDt.Text = DT.Rows[0]["LASTAPPLY"].ToString().Replace("12:00:00", "");
             TxtPlacc.Text       = DT.Rows[0]["PLACC"].ToString();
             TxtSTax.Text        = DT.Rows[0]["ST_SUBGL"].ToString();
             TxtCharges.Text     = DT.Rows[0]["CHARGES"].ToString();
             if (TxtPlacc.Text != null)
             {
                 string   STR = BD.GetAccTypeGL(TxtPlacc.Text, Session["BRCD"].ToString());
                 string[] CU  = STR.Split('_');
                 TxtPLName.Text = CU[0].ToString();
             }
             if (TxtSTax.Text != null)
             {
                 TxtSTaxName.Text = BD.GetAccType(TxtSTax.Text, Session["BRCD"].ToString());
             }
         }
         else
         {
             lblMessage.Text = "";
             lblMessage.Text = "Charges Master not Found....!";
             ModalPopup.Show(this.Page);
         }
     }
     catch (Exception Ex)
     {
         ExceptionLogging.SendErrorToText(Ex);
     }
 }
Пример #20
0
    protected void txtMemWelfare_TextChanged(object sender, EventArgs e)
    {
        try
        {
            AC1 = SP.Getaccno(txtMemWelfare.Text, Session["BRCD"].ToString());

            if (AC1 != null)
            {
                string[] AC = AC1.Split('_');;
                txtWelLoanProdName.Text = AC[1].ToString();

                txtShrSuspence.Focus();
                return;
            }
            else
            {
                txtMemWelfare.Text      = "";
                txtWelLoanProdName.Text = "";
                lblMessage.Text         = "Enter valid Product code...!!";
                ModalPopup.Show(this.Page);
                txtMemWelfare.Focus();
                return;
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
    protected void txtcusno_TextChanged(object sender, EventArgs e)
    {
        string AT = "";

        AT = CLS.Getstage1(txtcusno.Text, Session["BRCD"].ToString());
        if (AT != "1003")
        {
            WebMsgBox.Show("Sorry Customer not Authorise.........!!", this.Page);
            ModalPopup.Show(this.Page);
            txtcusno.Text   = "";
            txtcusname.Text = "";
            txtcusno.Focus();
        }
        else
        {
            string CUSTNAME = CLS.GetCustNAme(txtcusno.Text, Session["BRCD"].ToString());
            BindGrid();
            if (CUSTNAME != null || CUSTNAME != "")
            {
                txtcusname.Text = CUSTNAME;
                TxtAccno.Text   = txtcusno.Text;
                TxtFDate.Focus();
            }
            else
            {
                WebMsgBox.Show("Cust No Not Exit In Master   ...!!", this.Page);
                ModalPopup.Show(this.Page);
                return;
            }
        }
    }
Пример #22
0
 protected void txtShrSusName_TextChanged(object sender, EventArgs e)
 {
     try
     {
         CUNAME = txtShrSusName.Text;
         string[] custnob = CUNAME.Split('_');
         if (custnob.Length > 1)
         {
             txtShrSusName.Text  = custnob[0].ToString();
             txtShrSuspence.Text = (string.IsNullOrEmpty(custnob[1].ToString()) ? "" : custnob[1].ToString());
             txtOther3.Focus();
             return;
         }
         else
         {
             txtShrSuspence.Text = "";
             txtShrSusName.Text  = "";
             lblMessage.Text     = "Enter valid Product code...!!";
             ModalPopup.Show(this.Page);
             txtShrSuspence.Focus();
             return;
         }
     }
     catch (Exception Ex)
     {
         ExceptionLogging.SendErrorToText(Ex);
     }
 }
Пример #23
0
    protected void btncreate_Click(object sender, EventArgs e)
    {
        try
        {
            if (Session["UGRP"].ToString() != "1")// ADDED BY ANKITA 17/11/2017 TO ALLOW ONLY ADMIN TO ASSIGN PASSWRD
            {
                WebMsgBox.Show("Only ADMIN User can Assign new password to new user..!!", this.Page);
                return;
            }
            Result = cls.AssignPass(encrypt(txtEnterpwd.Text), txtlogincode.Text, Session["BRCD"].ToString());

            if (Result > 0)
            {
                lblMessage.Text = "Password assign successfully...!";
                ModalPopup.Show(this.Page);
                clear();
                FL = "Insert";//Dhanya Shetty
                string Res = CLM.LOGDETAILS(FL, Session["BRCD"].ToString(), Session["MID"].ToString(), "Assign_NewPasswrd _" + Session["LOGINCODE"].ToString() + "", "00", Session["MID"].ToString());
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
Пример #24
0
    protected void Txtdiv1_TextChanged(object sender, EventArgs e)
    {
        try
        {
            AC1 = SP.Getaccno(Txtdiv1.Text, Session["BRCD"].ToString());

            if (AC1 != null)
            {
                string[] AC = AC1.Split('_');;
                Txtdiv1name.Text = AC[1].ToString();
                Txtdiv2.Focus();
                return;
            }
            else
            {
                Txtdiv1.Text     = "";
                Txtdiv1name.Text = "";
                lblMessage.Text  = "Enter valid Product code...!!";
                ModalPopup.Show(this.Page);
                Txtdiv1.Focus();
                return;
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
 /// <summary>
 /// Initializes a new instance of the <see cref="AppPopup"/> class.
 /// </summary>
 public AppPopup()
 {
     this.popup = new Forms9Patch.ModalPopup()
     {
         Content = new Xamarin.Forms.ContentView(),
     };
 }
Пример #26
0
 protected void btnsave_Click(object sender, EventArgs e)
 {
     if (list_add_association.Count == 0 && list_delete_association.Count == 0)
     {
         UCModalError1.ShowMessageError = "ไม่ข้อมูลการทำรายการของคุณ";
         UCModalError1.ShowModalError();
     }
     else
     {
         var res = biz.AddAssocitionApplove(list_add_association, list_delete_association, base.UserId);//
         ModalPopup.Hide();
         GvCheckDoc.DataSource = biz.SelectApploveDocumentType("").DataResponse;
         GvCheckDoc.DataBind();
         if (res.IsError)
         {
             UCModalError1.ShowMessageError = "บันทึกข้อมูลไม่สำเร็จ";
             UCModalError1.ShowModalError();
         }
         else
         {
             UCModalSuccess1.ShowMessageSuccess = "บันทึกข้อมูลสำเร็จ";
             UCModalSuccess1.ShowModalSuccess();
         }
     }
 }
Пример #27
0
    protected void txtProdName_TextChanged(object sender, EventArgs e)
    {
        try
        {
            string[] custnob = txtProdName.Text.ToString().Split('_');
            if (custnob.Length > 1)
            {
                if (BD.GetProdOperate(txtBrCode.Text.ToString(), string.IsNullOrEmpty(custnob[2].ToString()) ? "" : custnob[2].ToString()).ToString() != "3")
                {
                    txtProdName.Text       = custnob[0].ToString();
                    ViewState["GlCode"]    = custnob[1].ToString();
                    txtProdType.Text       = (string.IsNullOrEmpty(custnob[2].ToString()) ? "" : custnob[2].ToString());
                    AutoAccname.ContextKey = txtBrCode.Text.ToString() + "_" + txtProdType.Text.ToString();

                    btnSubmit.Visible = true;
                    btnChange.Visible = false;
                    txtAccNo.Focus();
                }
                else
                {
                    ClearProdText();
                    lblMessage.Text = "Product is not operating...!!";
                    ModalPopup.Show(this.Page);
                    return;
                }
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
    protected void ddlBrName_SelectedIndexChanged(object sender, EventArgs e)
    {
        try
        {
            txtBrCode.Text = "";
            txtFDate.Text  = "";
            txtTDate.Text  = "";

            //Check user is admin or not
            string ADM = DOR.checkAdmin(Session["BRCD"].ToString(), Session["LOGINCODE"].ToString(), Session["MID"].ToString());

            if (ADM != null && ADM != "")
            {
                txtBrCode.Text = ddlBrName.SelectedValue.ToString();

                ViewState["EntryDate"] = DOR.openDay(txtBrCode.Text.Trim().ToString());

                txtFDate.Text = ViewState["EntryDate"].ToString();
                txtTDate.Text = "";
            }
            else
            {
                lblMessage.Text = "User Is Not Admin.. Please Login Admin User...!!";
                ModalPopup.Show(this.Page);
                return;
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
    protected void txtSetNo_TextChanged(object sender, EventArgs e)
    {
        try
        {
            if (txtSetNo.Text.Trim().ToString() == "")
            {
                lblMessage.Text = "Enter voucher number first...!!";
                ModalPopup.Show(this.Page);
                return;
            }
            else
            {
                string Cash = CD.CheckCashSet(Session["BRCD"].ToString(), Session["EntryDate"].ToString(), txtSetNo.Text.Trim().ToString());

                if (Cash != null && Cash != "")
                {
                    Amount         = CD.GetVoucherAmount(Session["BRCD"].ToString(), Session["EntryDate"].ToString(), txtSetNo.Text.Trim().ToString());
                    txtamount.Text = Convert.ToDouble(Convert.ToDouble(txtamount.Text.Trim().ToString()) + Convert.ToDouble(Amount)).ToString();
                }
                else
                {
                    lblMessage.Text = "Voucher is not of type-cash...!!";
                    ModalPopup.Show(this.Page);
                    return;
                }
            }
        }
        catch (Exception Ex)
        {
            ExceptionLogging.SendErrorToText(Ex);
        }
    }
Пример #30
0
 protected void TxtAccName_TextChanged(object sender, EventArgs e)
 {
     try
     {
         string   CUNAME  = TxtAccName.Text;
         string[] custnob = CUNAME.Split('_');
         if (custnob.Length > 1)
         {
             TxtAccName.Text = custnob[0].ToString();
             TxtAccNo.Text   = (string.IsNullOrEmpty(custnob[1].ToString()) ? "" : custnob[1].ToString());
             if (TxtAccNo.Text == "")
             {
                 TxtAccName.Text = "";
                 return;
             }
             ////added by ankita on 20/07/2017
             SumIwOw();
             Photo_Sign();
             TxtCheqNo.Focus();
         }
         else
         {
             lblMessage.Text = "Invalid Account Number.........!!";
             ModalPopup.Show(this.Page);
             return;
         }
     }
     catch (Exception Ex)
     {
         ExceptionLogging.SendErrorToText(Ex);
         //Response.Redirect("FrmLogin.aspx", true);
     }
 }