Esempio n. 1
0
        public void DeleteDBCDecaptcherData(string strDeathByCaptcha)
        {
            try
            {
                string strTable = "tb_Setting";
                string strQuery = "DELETE FROM tb_Setting WHERE FileType='" + strDeathByCaptcha + "'";

                DataBaseHandler.DeleteQuery(strQuery, strTable);
            }
            catch (Exception)
            {
            }
        }
Esempio n. 2
0
 public void UpdatePasswordForAccount(string userName, string newPassword)
 {
     try
     {
         string UpdateQuery = "update tb_LinkedInAccount set  Password='******' WHERE UserName='******';";
         DataBaseHandler.UpdateQuery(UpdateQuery, "tb_LinkedInAccount");
     }
     catch (Exception ex)
     {
         Console.WriteLine(ex.StackTrace);
         //AlibabaScaper.GlobusFileHelper.AppendStringToTextfileNewLine("InsertQuery error" +ex+ ex.StackTrace, MainFrm.Error);
     }
 }
Esempio n. 3
0
        public void InsertDBCData(string username, string DeathByCaptcha, string password)
        {
            try
            {
                string strQuery = "INSERT INTO tb_Setting VALUES ('" + username + "','" + DeathByCaptcha + "','" + password + "') ";

                DataBaseHandler.InsertQuery(strQuery, "tb_Setting");
            }
            catch (Exception)
            {
                UpdateSettingData(Upmodule, Upfiletype, Upfilepath);
            }
        }
Esempio n. 4
0
        public void UpdateSettingData(string module, string filetype, string filepath)
        {
            try
            {
                string strTable = "tb_Setting";
                string strQuery = "UPDATE tb_Setting SET Module='" + module + "', FilePath='" + filepath + "' WHERE FileType='" + filetype + "'";

                DataBaseHandler.UpdateQuery(strQuery, strTable);
            }
            catch (Exception)
            {
            }
        }
Esempio n. 5
0
        public void InsertDecaptcherData(string server, string port, string username, string password, string Decaptcher)
        {
            try
            {
                string strQuery = "INSERT INTO tb_Setting VALUES ('" + server + "<:>" + port + "','" + Decaptcher + "','" + username + "<:>" + password + "') ";

                DataBaseHandler.InsertQuery(strQuery, "tb_Setting");
            }
            catch (Exception)
            {
                UpdateSettingData(Upmodule, Upfiletype, Upfilepath);
            }
        }
Esempio n. 6
0
        public void UpdateFBAccount(string Usernaem, string password, string proxiaddress, string proxyport, string proxyName, string proxypassword)
        {
            try
            {
                string strTable = "tb_FBAccount";
                string strQuery = "UPDATE tb_FBAccount SET Password='******', ProxyAddress='" + proxiaddress + "', ProxyPort='" + proxyport + "', ProxyUserName='******', ProxyPassword='******' WHERE UserName='******'";

                DataBaseHandler.UpdateQuery(strQuery, strTable);
            }
            catch (Exception)
            {
                throw;
            }
        }
Esempio n. 7
0
        public DataTable SelectSettingData()
        {
            try
            {
                string strQuery = "SELECT * FROM tb_Setting";

                DataSet ds = DataBaseHandler.SelectQuery(strQuery, "tb_Setting");

                DataTable dt = ds.Tables["tb_Setting"];
                return(dt);
            }
            catch (Exception)
            {
                return(new DataTable());
            }
        }
Esempio n. 8
0
        public DataTable SelectAccoutsForGridView()
        {
            try
            {
                List <string> lstAccount = new List <string>();
                string        strQuery   = "SELECT * FROM tb_LinkedInAccount";

                DataSet ds = DataBaseHandler.SelectQuery(strQuery, "tb_LinkedInAccount");

                DataTable dt = ds.Tables["tb_LinkedInAccount"];

                return(dt);
            }
            catch (Exception)
            {
                return(new DataTable());
            }
        }
Esempio n. 9
0
        /// <summary>
        /// Inserts Settings in DataBase
        /// Updates if Settings already present
        /// </summary>
        /// <param name="module"></param>
        /// <param name="filetype"></param>
        /// <param name="filepath"></param>
        public void InsertOrUpdateSetting(string module, string filetype, string filepath)
        {
            try
            {
                this.Upmodule   = module;
                this.Upfiletype = filetype;
                this.Upfilepath = filepath;

                string Upmodule   = module;
                string UPfiletype = filetype;
                string strQuery   = "INSERT INTO tb_Setting VALUES ('" + module + "','" + filetype + "','" + filepath + "') ";

                DataBaseHandler.InsertQuery(strQuery, "tb_Setting");
            }
            catch (Exception)
            {
                UpdateSettingData(Upmodule, Upfiletype, Upfilepath);
            }
        }