private void btStart_Click(object sender, EventArgs e) //start button { //List<SimpleStringString> users = GetUsers(); //string IP = "10.0.30.46"; if (tbUrl.Text != "" && lbIpList.Items.Count > 0) { lbResults.Items.Clear(); pbProgress.Maximum = lbIpList.Items.Count; pbProgress.Minimum = 0; pbProgress.Value = 0; pbProgress.Step = 1; iMacros.App m_app = new iMacros.App(); foreach (string IP in lbIpList.Items) { DoWork(m_app, IP); pbProgress.PerformStep(); label3.Text = (pbProgress.Value * 100 / pbProgress.Maximum).ToString() + " %"; lbResults.SelectedIndex = lbResults.Items.Count - 1; lbResults.SelectedIndex = -1; } m_app.iimExit(); } }
private void cmdRun_Click(object sender, System.EventArgs e) { m_app = new iMacros.App(); iMacros.Status s; string macro = Iteration(); MessageBox.Show(macro); // macro = textBox2.Text; s = m_app.iimInit("", true, "", "", "", 5); s = m_app.iimSet("Username", "Rita"); s = m_app.iimPlayCode(macro, m_timeout); s = m_app.iimExit(m_timeout); /* */ /// LogStatus(s); }
private void btPlayOnly_Click(object sender, EventArgs e) { for (int i = 0; i < 3; i++) { iMacros.App m_app = new iMacros.App(); iMacros.Status s = m_app.iimInit("", false, "", "", "", 5); if (s == iMacros.Status.sOk || s == iMacros.Status.sInternal) { s = m_app.iimPlay(tbIIM.Text, 300); } string result = m_app.iimGetLastError(); System.Threading.Thread.Sleep(10000); m_app.iimExit(); } }