示例#1
0
 private void logDirStart_Click(object sender, EventArgs e)
 {
     if (Utils.IOHelper.isDir(oldLogDir.Text))
     {
         WelcomeForm.logDirPath = oldLogDir.Text;
         if (Directory.GetFiles(WelcomeForm.logDirPath, "logcat" + "*", SearchOption.AllDirectories).Length == 0)
         {
             MessageBox.Show("ops, wrong floder", "didn't find log files", MessageBoxButtons.OK, MessageBoxIcon.Warning);
         }
         else
         {
             Form logInfoForm = new LogcatFileShowForm(WelcomeForm.logDirPath, "logcat");
             logInfoForm.Show();
         }
     }
     else
     {
         MessageBox.Show("ops, should be a floder", "not a floder", MessageBoxButtons.OK, MessageBoxIcon.Warning);
     }
 }
 private void newLogStart_Click(object sender, EventArgs e)
 {
     if (Utils.IOHelper.isDir(newLogDir.Text))
     {
         WelcomeForm.logDirPath = newLogDir.Text;
         if (Directory.GetFiles(WelcomeForm.logDirPath, "mainlog" + "*", SearchOption.AllDirectories).Length == 0)
         {
             MessageBox.Show("ops, wrong floder", "didn't find log files", MessageBoxButtons.OK, MessageBoxIcon.Warning);
         }
         else
         {
             Form logInfoForm = new LogcatFileShowForm(WelcomeForm.logDirPath, "mainlog");
             logInfoForm.Show();
         }
     }
     else
     {
         MessageBox.Show("ops, should be a floder", "not a floder", MessageBoxButtons.OK, MessageBoxIcon.Warning);
     }
 }