fork download
  1. public partial class Form1 : Form
  2. {
  3.  
  4. private List<WebBrowser> browsers = new List<WebBrowser>();
  5.  
  6. public Form1()
  7. {
  8. InitializeComponent();
  9.  
  10. var wb = new WebBrowser();
  11. wb.Dock = DockStyle.Fill;
  12. wb.Tag = 1;
  13. wb.DocumentCompleted += this.wb_DocumentCompleted;
  14. this.browsers.Add(wb);
  15. this.tabPage1.Controls.Add(wb);
  16.  
  17. wb = new WebBrowser();
  18. wb.Dock = DockStyle.Fill;
  19. wb.Tag = 2;
  20. wb.DocumentCompleted += this.wb_DocumentCompleted;
  21. this.browsers.Add(wb);
  22. this.tabPage2.Controls.Add(wb);
  23. }
  24.  
  25. private void wb_DocumentCompleted(object sender, WebBrowserDocumentCompletedEventArgs e)
  26. {
  27. var wb = (WebBrowser)sender;
  28. Text = " i = [" + ((int)wb.Tag).ToString() + "]";
  29. }
  30.  
  31. private void Form1_Load(object sender, EventArgs e)
  32. {
  33. var urls = new string[] { "http://w...content-available-to-author-only...a.org/", "http://m...content-available-to-author-only...i.com/wiki/" };
  34.  
  35. for (int i = 0; i < browsers.Count; i++)
  36. {
  37. browsers[i].Navigate(urls[i]);
  38. }
  39. }
  40. }
Not running #stdin #stdout 0s 0KB
stdin
Standard input is empty
stdout
Standard output is empty