Курсовая работа: Подсистема управления процессами
public void Start()
{
a = new Thread(Base);
a.Start();
}
delegate void SetTextDelegate2(string Text);
public static EventWaitHandle WaitToStart;
public void SetText2(string Text)
{
if (reporter.InvokeRequired)
{
SetTextDelegate2 a = new SetTextDelegate2(SetText2);
reporter.Invoke(a, new object[] { Text });
}
else reporter.Text += Text;
}
public void Restart()
{
if(isWorking == true)
ChangeState();
timer = new Stopwatch();
a=new Thread(Base);
a.Start();
timer.Start();
}
}
}
using System;
using System.Collections.Generic;