Xojo.Threading.Thread.CurrentThread

From Xojo Documentation

Shared Method

Xojo.Threading.Thread.CurrentThread() As Xojo.Threading.Thread

Supported for all project types and targets.

The currently running thread.

Sample Code

Sleep the current thread for half a second:

Thread.CurrentThread.Sleep(500)