CreateResolvedPromise (open)

The CreateResolvedPromise function returns either a new promise resolved with the passed argument, or the argument itself if the argument is a promise produced by this constructor.

Syntax

LOADLIB "wh::promise.whlib";

OBJECT FUNCTION CreateResolvedPromise(VARIANT value)

Parameters

VARIANT value

Promise or value to resolve new promise with

Return value

OBJECT

Promise