I have a thread for example TMyThread, and then i have this
MyThread : TMyThread;
Then I have Button1 -> Onclick ->
If MyThread = nil then
MyThread := TMyThread.create;
And my thread goes on it's happy way. Now after 5 minutes when I click on the button again, nothing happens. It seems when the Thread is finished it dosn't set the varialbe back to nil.
How can I set MyThread variable to nil once the thread is complete? (freeonterminate is set to true).