Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private void button1_Click(object sender, EventArgs e)
- {
- webBrowser1.Navigate("https://m.facebook.com/messages/read/?fbid=" + listBox1.Text);
- C++;
- listBox1.SelectedItem = listBox1.Items[C - 1];
- timer1.Start();
- }
- private void timer1_Tick(object sender, EventArgs e)
- {
- var links = webBrowser1.Document.GetElementsByTagName("textarea");
- foreach (HtmlElement link in links)
- {
- if (richTextBox1.Text == richTextBox1.Text)
- {
- link.InnerText = richTextBox1.Text;
- }
- timer2.Start();
- }
- }
- private void timer2_Tick(object sender, EventArgs e)
- {
- var linkss = webBrowser1.Document.GetElementsByTagName("input");
- foreach (HtmlElement link in linkss)
- {
- if (link.Name == "Send" || link.Name == "send")
- {
- if (richTextBox1.Text != "")
- {
- link.InvokeMember("click");
- }
- }
- timer3.Start();
- }
- }
- private void timer3_Tick(object sender, EventArgs e)
- {
- webBrowser1.Navigate("https://m.facebook.com/messages/read/?fbid=" + listBox1.Text);
- timer1.Start();
- C++;
- listBox1.SelectedItem = listBox1.Items[C - 1];
- }
- private void button2_Click(object sender, EventArgs e)
- {
- listBox1.Items.Clear();
- OpenFileDialog theDialog = new OpenFileDialog();
- theDialog.Title = "Open Text File";
- theDialog.Filter = "TXT files|*.txt";
- if (theDialog.ShowDialog() == DialogResult.OK)
- {
- string Name = theDialog.FileName.ToString();
- if (File.Exists(Name))
- {
- var lines = File.ReadAllLines(Name);
- foreach (var line in lines)
- {
- listBox1.Items.Add(line);
- listBox1.SelectedItem = listBox1.Items[listBox1.Items.Count - 1];
- var ID = line.Split(new string[] { " : " }, StringSplitOptions.RemoveEmptyEntries);
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement