protected void Page_Load(object sender, EventArgs e)
    {
        try
        {
            string strPreviousPage = "";
            if (Request.UrlReferrer != null)
            {
                strPreviousPage = Request.UrlReferrer.Segments[Request.UrlReferrer.Segments.Length - 1];

                if (Session["AdvisorID"] == null || Session["AdvisorID"].ToString() == "")
                {
                    Response.Redirect("../AdminLogin.aspx", false);
                }
            }
            if (strPreviousPage == "")
            {
                Response.Redirect("~/AdminLogin.aspx");
            }
            if (!IsPostBack)
            {
                _objComman.GetProvince(ddlProvince);
                _objComman.GetCity(ddlCity);
            }
        }
        catch
        {
            lblTitle.Text      = "Warning!";
            lblTitle.ForeColor = System.Drawing.Color.Red;
            message.ForeColor  = System.Drawing.Color.Red;
            message.Text       = "Sorry, Something went wrong, please contact administrator";
            ScriptManager.RegisterStartupScript(this, this.GetType(), "Pop", "openModal();", true);
        }
    }
Пример #2
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!IsPostBack)
     {
         _objComman.GetProvince(ddlProvince);
         _objComman.GetCity(ddlCity);
     }
 }
Пример #3
0
    protected void Page_Load(object sender, EventArgs e)
    {
        try
        {
            string strPreviousPage = "";
            if (Request.UrlReferrer != null)
            {
                strPreviousPage = Request.UrlReferrer.Segments[Request.UrlReferrer.Segments.Length - 1];

                if (Session["AdvisorID"] == null || Session["AdvisorID"].ToString() == "")
                {
                    Response.Redirect("../AdminLogin.aspx", false);
                }
                else
                {
                    if (!IsPostBack)
                    {
                        _objComman.GetProvince(ddlProvince);
                        _objComman.GetCity(ddlCity);
                        _objComman.getRecordsPerPage(DropPage);
                        _objComman.getRecordsPerPage(DropPageValidate);
                        _objComman.getRecordsPerPage(DropPageFeedback);
                        GetGridData();
                        BindAdvisors();
                        //ValidateGridData();
                        //FeedbackGridData();
                        sectionClientList.Visible     = true;
                        editSection.Visible           = false;
                        statusSection.Visible         = false;
                        validateSection.Visible       = false;
                        ClientFeedbackSection.Visible = false;
                        lblResignedDate.Visible       = false;
                        txtResignedDate.Visible       = false;
                        rfvResignedDate.Enabled       = false;
                    }
                }
            }
            if (strPreviousPage == "")
            {
                Response.Redirect("~/AdminLogin.aspx");
            }
        }
        catch
        {
            lblTitle.Text      = "Warning!";
            lblTitle.ForeColor = System.Drawing.Color.Red;
            message.ForeColor  = System.Drawing.Color.Red;
            message.Text       = "Sorry, Something went wrong, please contact administrator";
            ScriptManager.RegisterStartupScript(this, this.GetType(), "Pop", "openModal();", true);
        }
    }
Пример #4
0
    protected void Page_Load(object sender, EventArgs e)
    {
        try
        {
            string strPreviousPage = "";
            if (Request.UrlReferrer != null)
            {
                strPreviousPage = Request.UrlReferrer.Segments[Request.UrlReferrer.Segments.Length - 1];
                if (Session["SAID"] == null || Session["SAID"].ToString() == "")
                {
                    Response.Redirect("../ClientLogin.aspx", false);
                }
                else
                {
                    if (!IsPostBack)
                    {
                        _objComman.GetCountry(ddlCountry);
                        _objComman.GetProvince(ddlProvince);

                        _objComman.GetAccountType(ddlAccountType);
                        _objComman.getRecordsPerPage(DropPage);
                        _objComman.getRecordsPerPage(DropPage1);
                        _objComman.getRecordsPerPage(dropPage2);
                        _objComman.getRecordsPerPage(DropPageDocuments);
                        BindParentDetails();
                        chkClientAddress.Visible = false;
                        GetClientAddress();
                        //btnUpdateParents.Visible = false;
                        BindAddressDetails();
                        BindBankDetails();
                        Disable();
                        BindDocumentList();
                    }
                    if (this.IsPostBack)
                    {
                        if (Request.Form[TabName.UniqueID].Contains("gvParent"))
                        {
                            TabName.Value = "tab1";
                        }
                        else if (Request.Form[TabName.UniqueID].Contains("gdvBankList"))
                        {
                            TabName.Value = "tab2";
                        }
                        else if (Request.Form[TabName.UniqueID].Contains("gvAddress"))
                        {
                            TabName.Value = "tab3";
                        }
                        else if (Request.Form[TabName.UniqueID].Contains("gvDocumentsList"))
                        {
                            TabName.Value = "tabDocumentsList";
                        }
                        else
                        {
                            TabName.Value = Request.Form[TabName.UniqueID];
                        }
                    }
                }
            }
            if (strPreviousPage == "")
            {
                Response.Redirect("~/ClientLogin.aspx");
            }
        }
        catch
        {
            lblTitle.Text      = "Warning!";
            lblTitle.ForeColor = System.Drawing.Color.Red;
            message.ForeColor  = System.Drawing.Color.Red;
            message.Text       = "Sorry, Something went wrong, please contact administrator";
            ScriptManager.RegisterStartupScript(this, this.GetType(), "Pop", "openModal();", true);
        }
    }