Quantcast
Channel: Windows Forms Data Controls and Databinding forum
Viewing all articles
Browse latest Browse all 2535

Thread and timer

$
0
0

I want to develop an application which runs a thread and a timer simultaneously. Thread is responsible for getting data. On clicking button, thread is created which takes the data and on clicking the button again, thread is destroyed. In parallel, timer is required to time the duration of run of thread.

When i start timer in this function "private: System::Void StartBtn_Click" by using start function. The timer doesnt start timing. When i click again without stopping the function then timer starts calculating the time and starts clocking.

how to run thread and timer together on clickung start button



Viewing all articles
Browse latest Browse all 2535

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>