Exemple #1
0
        public static clsUseFollowSetting GetObject()
        {
            if (obj_clsUseFollowSetting == null)
            {
                try
                {
                    obj_clsUseFollowSetting = new clsUseFollowSetting();
                }
                catch
                {
                }
            }

            return(obj_clsUseFollowSetting);
        }
        public static clsUseFollowSetting GetObject()
        {
            if (obj_clsUseFollowSetting == null)
            {
                
                try
                {
                    obj_clsUseFollowSetting = new clsUseFollowSetting();

                }
                catch
                {
                }
            }
            
            return obj_clsUseFollowSetting;
        }
        private void btnSet_Click(object sender, EventArgs e)
        {
            try
            {
                clsUseFollowSetting obj_clsUseFollowSetting = clsUseFollowSetting.GetObject();

                if (chkDontFollowUsersThatUnfollowedBefore.Checked)
                {
                    try
                    {
                        obj_clsUseFollowSetting._DontFollowUsersThatUnfollowedBefore = true;
                    }
                    catch
                    {
                    }
                }

                if (chkDontFollowUsersWithNoPicture.Checked)
                {
                    try
                    {
                        obj_clsUseFollowSetting._DontFollowUsersWithNoPicture = true;
                    }
                    catch
                    {
                    }
                }

                if (chkDontFollowUsersWithManyLinks.Checked)
                {
                    try
                    {
                        obj_clsUseFollowSetting._DontFollowUsersWithManyLinks = true;
                        obj_clsUseFollowSetting._NoOfLinks = Convert.ToInt32(txtNoOfLinks.Text);
                    }
                    catch
                    {
                    }
                }

                if (chkDontFollowUsersWithFollowingsFollowersRatio.Checked)
                {
                    try
                    {
                        obj_clsUseFollowSetting._DontFollowUsersWithFollowingsFollowersRatio = true;
                        obj_clsUseFollowSetting._FollowingsFollowersRatio = Convert.ToInt32(txtFollowingsFollowersRatio.Text);
                    }
                    catch
                    {
                    }
                }

                if (chkBox_NoOFfollow.Checked)
                {
                    try
                    {
                        obj_clsUseFollowSetting._NoOFfollow    = true;
                        obj_clsUseFollowSetting._MaximumFollow = Convert.ToInt32(txt_MaximumFollow.Text);
                    }
                    catch
                    {
                    }
                }

                if (chkboxUseGroups.Checked)
                {
                    try
                    {
                        obj_clsUseFollowSetting._UseGroups = true;
                        obj_clsUseFollowSetting._UseGroup  = txtUseGroup.Text;
                    }
                    catch
                    {
                    }
                }

                if (MessageBox.Show("Follow Setting Is Set !", "Notification", MessageBoxButtons.OK) == DialogResult.OK)
                {
                    this.Close();
                }
            }
            catch
            {
            }
        }