End Google Ads 201810 - BS.net 01 --> I have following code in my start button which starts the process.
void BtnStartClick(object sender, EventArgs e)
{
btnStart.Enabled=pdfStopped=xmlStopped=false;
btnStop.Enabled=true;
ThreadPool.QueueUserWorkItem(new WaitCallback(Startup));
}
void Startup(object s)
{
try
{
Start();
timGeneral.Enabled=true;
timGeneral.Start();
}
catch(Exception){}
}
void Start()
{
pdfThread=new Thread(new ThreadStart(pdfDownloadStart));
pdfThread.IsBackground=true;
pdfThread.Start();
xmlThread=new Thread(new ThreadStart(startXMLDownload));
xmlThread.IsBackground=true;
xmlThread.Start();
pdfStThread = new Thread(new ThreadStart(createPdfFileStructure));
pdfStThread.IsBackground = true;
pdfStThread.Start();
}
well i am trying to stop all these running threads in stop button, but i could not achieve it
how can i stop all threads?

Abdul Rahaman Hamidy
Database Developer
Kabul, Afghanistan