Example #1
0
 protected void rbtnNonIndividual_CheckedChanged(object sender, EventArgs e)
 {
     try
     {
         dtCustomerSubType                 = XMLBo.GetCustomerSubType(path, "NIND");
         ddlCustomerSubType.DataSource     = dtCustomerSubType;
         ddlCustomerSubType.DataTextField  = "CustomerTypeName";
         ddlCustomerSubType.DataValueField = "CustomerSubTypeCode";
         ddlCustomerSubType.DataBind();
         ddlCustomerSubType.Items.Insert(0, new ListItem("Select a Sub-Type", "Select a Sub-Type"));
         trIndividualName.Visible    = false;
         trNonIndividualName.Visible = true;
     }
     catch (BaseApplicationException Ex)
     {
         throw Ex;
     }
     catch (Exception Ex)
     {
         BaseApplicationException exBase       = new BaseApplicationException(Ex.Message, Ex);
         NameValueCollection      FunctionInfo = new NameValueCollection();
         FunctionInfo.Add("Method", "CustomerType.ascx:rbtnNonIndividual_CheckedChanged()");
         object[] objects = new object[1];
         objects[0]   = path;
         FunctionInfo = exBase.AddObject(FunctionInfo, objects);
         exBase.AdditionalInformation = FunctionInfo;
         ExceptionManager.Publish(exBase);
         throw exBase;
     }
 }
        private void BindDropDowns(string path)
        {
            DataTable dtStates = XMLBo.GetStates(path);

            ddlCorrAdrState.DataSource     = dtStates;
            ddlCorrAdrState.DataValueField = "StateCode";
            ddlCorrAdrState.DataTextField  = "StateName";
            ddlCorrAdrState.DataBind();
            ddlCorrAdrState.Items.Insert(0, new ListItem("Select a State", "Select a State"));


            ddlPermAdrState.DataSource     = dtStates;
            ddlPermAdrState.DataValueField = "StateCode";
            ddlPermAdrState.DataTextField  = "StateName";
            ddlPermAdrState.DataBind();
            ddlPermAdrState.Items.Insert(0, new ListItem("Select a State", "Select a State"));

            if (customerVo.Type.ToUpper().ToString() == "IND")
            {
                dtCustomerSubType = XMLBo.GetCustomerSubType(path, "IND");
            }
            else
            {
                dtCustomerSubType = XMLBo.GetCustomerSubType(path, "NIND");
            }
            ddlCustomerSubType.DataSource     = dtCustomerSubType;
            ddlCustomerSubType.DataTextField  = "CustomerTypeName";
            ddlCustomerSubType.DataValueField = "CustomerSubTypeCode";
            ddlCustomerSubType.DataBind();
            ddlCustomerSubType.SelectedValue = customerVo.SubType;
        }
 private void BindSubTypeDropDown(string type)
 {
     try
     {
         DataTable dtCustomerSubType = XMLBo.GetCustomerSubType(path, type);
         ddlCustomerSubType.DataSource     = dtCustomerSubType;
         ddlCustomerSubType.DataTextField  = "CustomerTypeName";
         ddlCustomerSubType.DataValueField = "CustomerSubTypeCode";
         ddlCustomerSubType.DataBind();
         ddlCustomerSubType.Items.Insert(0, new ListItem("Select", "Select"));
     }
     catch (BaseApplicationException Ex)
     {
         throw Ex;
     }
     catch (Exception Ex)
     {
         BaseApplicationException exBase       = new BaseApplicationException(Ex.Message, Ex);
         NameValueCollection      FunctionInfo = new NameValueCollection();
         FunctionInfo.Add("Method", "CompleteCustomerProfile.ascx:rbtnIndividual_CheckedChanged()");
         object[] objects = new object[1];
         objects[0]   = path;
         FunctionInfo = exBase.AddObject(FunctionInfo, objects);
         exBase.AdditionalInformation = FunctionInfo;
         ExceptionManager.Publish(exBase);
         throw exBase;
     }
 }
Example #4
0
        protected void rbtnNonIndividual_CheckedChanged(object sender, EventArgs e)
        {
            dtCustomerSubType                 = XMLBo.GetCustomerSubType(path, "NIND");
            ddlCustomerSubType.DataSource     = dtCustomerSubType;
            ddlCustomerSubType.DataTextField  = "CustomerTypeName";
            ddlCustomerSubType.DataValueField = "CustomerSubTypeCode";
            ddlCustomerSubType.DataBind();
            ddlCustomerSubType.Items.Insert(0, new ListItem("Select a Sub-Type", "Select a Sub-Type"));

            trCompanyName.Visible    = true;
            trIndividualName.Visible = false;
        }
 protected void rbtnNonIndividual_CheckedChanged(object sender, EventArgs e)
 {
     dtCustomerSubType                 = XMLBo.GetCustomerSubType(path, "NIND");
     ddlCustomerSubType.DataSource     = dtCustomerSubType;
     ddlCustomerSubType.DataTextField  = "CustomerTypeName";
     ddlCustomerSubType.DataValueField = "CustomerSubTypeCode";
     ddlCustomerSubType.DataBind();
     if (customerVo != null)
     {
         Session[SessionContents.CustomerVo] = customerVo;
         ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "PageLoadScript", "loadcontrol('EditCustomerNonIndividualProfile','none');", true);
     }
 }
Example #6
0
        private void BindSubTypeDropDown()
        {
            try
            {
                dtCustomerSubType                 = XMLBo.GetCustomerSubType(path, "IND");
                ddlCustomerSubType.DataSource     = dtCustomerSubType;
                ddlCustomerSubType.DataTextField  = "CustomerTypeName";
                ddlCustomerSubType.DataValueField = "CustomerSubTypeCode";
                ddlCustomerSubType.DataBind();
                ddlCustomerSubType.Items.Insert(0, new ListItem("Select", "Select"));

                //txtFirstName.Visible = true;
                //txtMiddleName.Visible = true;
                //txtLastName.Visible = true;
                //lblName.Visible = true;
                //txtCompanyName.Visible = false;
                //lblCompanyName.Visible = false;
                trIndividualName.Visible    = true;
                trNonIndividualName.Visible = false;
            }
            catch (BaseApplicationException Ex)
            {
                throw Ex;
            }
            catch (Exception Ex)
            {
                BaseApplicationException exBase       = new BaseApplicationException(Ex.Message, Ex);
                NameValueCollection      FunctionInfo = new NameValueCollection();
                FunctionInfo.Add("Method", "CustomerType.ascx:rbtnIndividual_CheckedChanged()");
                object[] objects = new object[1];
                objects[0]   = path;
                FunctionInfo = exBase.AddObject(FunctionInfo, objects);
                exBase.AdditionalInformation = FunctionInfo;
                ExceptionManager.Publish(exBase);
                throw exBase;
            }
        }
        private void BindDropDowns(string path)
        {
            AdvisorVo advisorVo = new AdvisorVo();

            try
            {
                dtState = commonLookupBo.GetWERPLookupMasterValueList(14000, 0);

                ddlCorrAdrState.DataSource     = dtState;
                ddlCorrAdrState.DataTextField  = "WCMV_Name";
                ddlCorrAdrState.DataValueField = "WCMV_LookupId";
                ddlCorrAdrState.DataBind();
                ddlCorrAdrState.Items.Insert(0, new ListItem("--SELECT--", "0"));

                ddlPermAdrState.DataSource     = dtState;
                ddlPermAdrState.DataTextField  = "WCMV_Name";
                ddlPermAdrState.DataValueField = "WCMV_LookupId";
                ddlPermAdrState.DataBind();
                ddlPermAdrState.Items.Insert(0, new ListItem("--SELECT--", "0"));

                dtOccupation                 = commonLookupBo.GetWERPLookupMasterValueList(3000, 0);
                ddlOccupation.DataSource     = dtOccupation;
                ddlOccupation.DataTextField  = "WCMV_Name";
                ddlOccupation.DataValueField = "WCMV_LookupId";
                ddlOccupation.DataBind();
                ddlOccupation.Items.Insert(0, new ListItem("--SELECT--", "0"));

                dtNationality                 = XMLBo.GetNationality(path);
                ddlNationality.DataSource     = dtNationality;
                ddlNationality.DataTextField  = "Nationality";
                ddlNationality.DataValueField = "NationalityCode";
                ddlNationality.DataBind();
                ddlNationality.Items.Insert(0, new ListItem("Select a Nationality", "Select a Nationality"));

                dtCity = commonLookupBo.GetWERPLookupMasterValueList(8000, 0);

                ddlCorrAdrCity.DataSource     = dtCity;
                ddlCorrAdrCity.DataTextField  = "WCMV_Name";
                ddlCorrAdrCity.DataValueField = "WCMV_LookupId";
                ddlCorrAdrCity.DataBind();
                ddlCorrAdrCity.Items.Insert(0, new ListItem("--SELECT--", "0"));

                ddlPermAdrCity.DataSource     = dtCity;
                ddlPermAdrCity.DataTextField  = "WCMV_Name";
                ddlPermAdrCity.DataValueField = "WCMV_LookupId";
                ddlPermAdrCity.DataBind();
                ddlPermAdrCity.Items.Insert(0, new ListItem("--SELECT--", "0"));


                if (customerVo.Type == null || customerVo.Type.ToUpper().ToString() == "IND")
                {
                    dtCustomerSubType = XMLBo.GetCustomerSubType(path, "IND");
                }
                else
                {
                    dtCustomerSubType = XMLBo.GetCustomerSubType(path, "NIND");
                }
                //ddlCustomerSubType.DataSource = dtCustomerSubType;
                //ddlCustomerSubType.DataTextField = "CustomerTypeName";
                //ddlCustomerSubType.DataValueField = "CustomerSubTypeCode";
                //ddlCustomerSubType.DataBind();
                //ddlCustomerSubType.SelectedValue = customerVo.SubType;
            }
            catch (BaseApplicationException Ex)
            {
                throw Ex;
            }

            catch (Exception Ex)
            {
                BaseApplicationException exBase       = new BaseApplicationException(Ex.Message, Ex);
                NameValueCollection      FunctionInfo = new NameValueCollection();

                FunctionInfo.Add("Method", "EditCustomerIndividualProfile.ascx:BindDropDowns()");

                object[] objects = new object[0];

                FunctionInfo = exBase.AddObject(FunctionInfo, objects);
                exBase.AdditionalInformation = FunctionInfo;
                ExceptionManager.Publish(exBase);
                throw exBase;
            }
        }
        private void BindDropDowns()
        {
            AdvisorVo advisorVo = new AdvisorVo();

            try
            {
                dtMaritalStatus                 = XMLBo.GetMaritalStatus(path);
                ddlMaritalStatus.DataSource     = dtMaritalStatus;
                ddlMaritalStatus.DataTextField  = "MaritalStatus";
                ddlMaritalStatus.DataValueField = "MaritalStatusCode";
                ddlMaritalStatus.DataBind();
                ddlMaritalStatus.Items.Insert(0, new ListItem("Select a Status", "Select a Status"));

                dtNationality                 = XMLBo.GetNationality(path);
                ddlNationality.DataSource     = dtNationality;
                ddlNationality.DataTextField  = "Nationality";
                ddlNationality.DataValueField = "NationalityCode";
                ddlNationality.DataBind();
                ddlNationality.Items.Insert(0, new ListItem("Select a Nationality", "Select a Nationality"));

                dtOccupation                 = XMLBo.GetOccupation(path);
                ddlOccupation.DataSource     = dtOccupation;
                ddlOccupation.DataTextField  = "Occupation";
                ddlOccupation.DataValueField = "OccupationCode";
                ddlOccupation.DataBind();
                ddlOccupation.Items.Insert(0, new ListItem("Select a Occupation", "Select a Occupation"));

                dtQualification                 = XMLBo.GetQualification(path);
                ddlQualification.DataSource     = dtQualification;
                ddlQualification.DataTextField  = "Qualification";
                ddlQualification.DataValueField = "QualificationCode";
                ddlQualification.DataBind();
                ddlQualification.Items.Insert(0, new ListItem("Select a Qualification", "Select a Qualification"));

                dtState = XMLBo.GetStates(path);

                ddlCorrAdrState.DataSource     = dtState;
                ddlCorrAdrState.DataTextField  = "StateName";
                ddlCorrAdrState.DataValueField = "StateCode";
                ddlCorrAdrState.DataBind();
                ddlCorrAdrState.Items.Insert(0, new ListItem("Select a State", "Select a State"));

                ddlPermAdrState.DataSource     = dtState;
                ddlPermAdrState.DataTextField  = "StateName";
                ddlPermAdrState.DataValueField = "StateCode";
                ddlPermAdrState.DataBind();
                ddlPermAdrState.Items.Insert(0, new ListItem("Select a State", "Select a State"));

                ddlOfcAdrState.DataSource     = dtState;
                ddlOfcAdrState.DataTextField  = "StateName";
                ddlOfcAdrState.DataValueField = "StateCode";
                ddlOfcAdrState.DataBind();
                ddlOfcAdrState.Items.Insert(0, new ListItem("Select a State", "Select a State"));

                if (customerVo.Type.ToUpper().ToString() == "IND")
                {
                    dtCustomerSubType = XMLBo.GetCustomerSubType(path, "IND");
                }
                else
                {
                    dtCustomerSubType = XMLBo.GetCustomerSubType(path, "NIND");
                }
                ddlCustomerSubType.DataSource     = dtCustomerSubType;
                ddlCustomerSubType.DataTextField  = "CustomerTypeName";
                ddlCustomerSubType.DataValueField = "CustomerSubTypeCode";
                ddlCustomerSubType.DataBind();
                ddlCustomerSubType.SelectedValue = customerVo.SubType;
            }
            catch (BaseApplicationException Ex)
            {
                throw Ex;
            }

            catch (Exception Ex)
            {
                BaseApplicationException exBase       = new BaseApplicationException(Ex.Message, Ex);
                NameValueCollection      FunctionInfo = new NameValueCollection();

                FunctionInfo.Add("Method", "EditCustomerIndividualProfile.ascx:BindDropDowns()");

                object[] objects = new object[0];

                FunctionInfo = exBase.AddObject(FunctionInfo, objects);
                exBase.AdditionalInformation = FunctionInfo;
                ExceptionManager.Publish(exBase);
                throw exBase;
            }
        }