thread_object.Start Method

Starts the execution of an independent thread.

thread_object.Start()

Prerequisites

The procedure associated with thread_object must be declared Public. The procedure associated with thread_object must be loaded into memory and compiled without errors.

Parameters

None

Remarks

This method begins a new thread that executes the procedure associated with the thread_object, just as if a console Start command were issued. If the thread is currently active, this method does nothing and returns without error. If the thread is currently paused, it is restarted by clearing the execution stack and executing the procedure associated with the object. If a thread is stopped by using the Abort method, it can only be restarted by using Start. If the project or procedure associated with the object does not exist, or if there were any errors compiling the project, this method issues an error. To pass a numeric argument to the thread, see the thread_object.Argument property.

Examples

Dim thread1 As New Thread(“Test”) ' Create a thread object to execute the
' Public procedure Test in the current project
thread1.Start() ' Start the thread

See Also

Thread Class | thread_object.Abort| thread_object.Argument