コード例 #1
0
        private bool SaveValidation()



        {
            bool ressult;

            try
            {
                //if all existing in list
                if (CMX_City.IsItemInList() && CMX_Area.IsItemInList())
                {   //check text name of church
                    if (TXT_Church.Text != "")
                    {
                        ressult = true;
                    }
                    else
                    {
                        MessageBox.Show("please enter church name");
                        TXT_Church.Focus();
                        ressult = false;
                    }
                }
                else
                {
                    ressult = false;
                }
            }
            catch (Exception)
            {
                ressult = false;
            }

            return(ressult);
        }
コード例 #2
0
ファイル: FRM_Login.cs プロジェクト: arsanyayoub/GoodSHepherd
        private void FRM_Login_Load(object sender, EventArgs e)
        {
            // MessageBox.Show("Load Login !!!!!!!!!!!!!!");
            CMX_City.Focus();
            CMX_City.SelectAll();
            this.tBL_CityTableAdapter.Fill(this.userChurchDataSet.TBL_City);

            Properties.Settings.Default["GoodShepherdConnectionString"] = BasicClass.vConectionString;
            this.tBL_UserTableAdapter.Connection = BasicClass.vSqlConn;
            //MessageBox.Show("End Login !!!!!!!!!!!!!!");
        }
コード例 #3
0
ファイル: FRM_Login.cs プロジェクト: arsanyayoub/GoodSHepherd
        private void CMX_City_ValueChanged(object sender, EventArgs e)
        {
            if (CMX_City.Text != "" && CMX_City.IsItemInList())
            {
                this.vIW_ChurchTableAdapter.FillByCity(this.userChurchDataSet.VIW_Church, int.Parse(CMX_City.Value.ToString()));
            }
            else
            {
                CMX_City.Value = null;
            }

            if (!CMX_Church.IsItemInList())
            {
                CMX_Church.Value   = null;
                CMX_UserName.Value = null;
            }
        }