What happened to Thread.Finished?

It seems that in API 2.0, Thread no longer has a Finished event, so how do I know when a thread has finished? I have to set a timer to keep checking NotRunning? Why would Xojo remove such a useful event?

Never knew that even existed.

We always did a CallLater to do this:

xojo.Timer.CallLater 0, AddressOf MyThreadFinished

I don’t recall there being a Finished event, but you could subclass and add one of your own.

i remember
i used define event and raise event in a thread but you can not use it in a window.

Was that maybe the task subclass in one of the examples?

I just checked the old API, 2018r3, and Threads have only a Run event, nothing else.

You’re probably thinking of the Thread subclass called “Task” that was in the example project UIThreadingWithTask. It has a Finished event defined. Looks like the example isn’t in the set of examples included with 2019r3.1. Perhaps it was removed since it’s essentially been superseded by the API2 Thread.UserInterfaceUpdate event.

Yep. I was looking at my code that was using the Task subclass, not a Thread.