The requested page is not available for the requested platform. You are viewing the content for Default platform.

Execute Statement Asynchronously (StartNew)

Passes the current statement to the StartNew method of Task.Factory, launching an asynchronous operation and returning a handle to the associated Task.

Availability

Available from the context menu or via shortcuts:

  • when the caret is on a method call.

Example

bool IsSym = IsSymmetric("MyString");
Dim IsSys As Boolean = IsSymmetric("MyString")

Result:

var t = Task<bool>.Factory.StartNew(() =>
{
    return IsSymmetric("MyString");
});
t.Wait();
Dim t = Task(Of Boolean).Factory.StartNew(Function() IsSymmetric("MyString"))
t.Wait()

Screenshot

rsExecuteStatementsAsynchronouslyStartNew