Exemplo n.º 1
0
        private void loginMethod()
        {
            CookieContainer cookieC  = new CookieContainer();
            bool            loggedIn = MainCode.Login(textBox1.Text + ":" + textBox2.Text, null, cookieC);

            Console.WriteLine(loggedIn);
            if (loggedIn)
            {
                HTTP.GetSourceNormal("http://friendlife.com/lifestylez/friends", Form1.timeout, null, cookieC);
            }
        }
Exemplo n.º 2
0
 private void SendMsg()
 {
     try
     {
         pts = new CancellationTokenSource();
         string message = textBox3.Text;
         pmsent = 0;
         var options = new ParallelOptions()
         {
             MaxDegreeOfParallelism = Convert.ToInt32(numericUpDown2.Value),
             CancellationToken      = pts.Token
         };
         Parallel.ForEach(profilelinks, options, profileurl =>
         {
             try
             {
                 string proxi = null;
                 if (checkBox3.Checked && proxies.Count > 0)
                 {
                     proxi = proxies[rad.Next(proxies.Count)];
                 }
                 string logindetails = details[rad.Next(details.Count)];
                 MainCode.SendMessage(logindetails, profileurl, message, proxi);
             }
             catch (Exception ex)
             {
                 //MessageBox.Show(ex.ToString());
             }
             finally
             {
                 //pcount = pcount + 1;
             }
         });
     }
     catch
     {
     }
     finally
     {
         button19.Enabled = true;
     }
 }
Exemplo n.º 3
0
 private void CommentThread()
 {
     try
     {
         var options = new ParallelOptions()
         {
             MaxDegreeOfParallelism = Convert.ToInt32(numericUpDown2.Value),
             CancellationToken      = cts.Token
         };
         remurls = commentonlinks.Count;
         Parallel.ForEach(commentonlinks, options, link =>
         {
             try
             {
                 string login = details[rad.Next(details.Count)];
                 string proxi = null;
                 if (checkBox3.Checked && proxies.Count > 0)
                 {
                     proxi = proxies[rad.Next(proxies.Count)];
                 }
                 MainCode.Comment(link, proxi, login, checkBox4.Checked, checkBox5.Checked, checkBox6.Checked);
             }
             catch
             {
             }
             finally
             {
                 remurls         = remurls - 1;
                 commentprogress = commentprogress + 1;
             }
         });
         button10.Enabled = true;
         MessageBox.Show("CompleteD");
         //marqueeProgressBarControl1.Properties.Stopped = true;
     }
     catch (OperationCanceledException ex)
     {
         button6.Enabled = true;
         MessageBox.Show("CompleteD");
         //marqueeProgressBarControl1.Properties.Stopped = true;
     }
 }
Exemplo n.º 4
0
 private void UploadCode()
 {
     try
     {
         cts    = new CancellationTokenSource();
         pcount = 0;
         var options = new ParallelOptions()
         {
             MaxDegreeOfParallelism = Convert.ToInt32(numericUpDown2.Value),
             CancellationToken      = cts.Token
         };
         Parallel.ForEach(details, options, login =>
         {
             try
             {
                 string proxi = null;
                 if (checkBox3.Checked && proxies.Count > 0)
                 {
                     proxi = proxies[rad.Next(proxies.Count)];
                 }
                 MainCode.Upload(login, proxi);
             }
             catch (Exception ex)
             {
                 //MessageBox.Show(ex.ToString());
             }
             finally
             {
                 pcount = pcount + 1;
             }
         });
         button6.Enabled = true;
         MessageBox.Show("CompleteD");
     }
     catch (OperationCanceledException ex)
     {
         button6.Enabled = true;
         MessageBox.Show("CompleteD");
     }
 }
Exemplo n.º 5
0
 private void StartRegister()
 {
     try
     {
         pcount = 0;
         int noofaccounts = Convert.ToInt32(numericUpDown1.Value);
         int threads      = Convert.ToInt32(numericUpDown2.Value);
         var options      = new ParallelOptions()
         {
             CancellationToken      = cts.Token,
             MaxDegreeOfParallelism = threads,
         };
         Parallel.For(0, noofaccounts, options, i =>
         {
             try
             {
                 string proxi = null;
                 if (checkBox3.Checked && proxies.Count > 0)
                 {
                     proxi = proxies[rad.Next(proxies.Count)];
                 }
                 MainCode.Register(proxi, checkBox2.Checked);
                 //pcount = pcount + 1;
             }
             catch { }
             finally { pcount = pcount + 1; }
         });
         button2.Enabled = true;
         MessageBox.Show("Completed");
     }
     catch (OperationCanceledException ex)
     {
         button6.Enabled = true;
         MessageBox.Show("CompleteD");
     }
 }
Exemplo n.º 6
0
 private void process()
 {
     MainCode.Register(null, true);
 }