Skip to main content

overwolf.media.takeWindowsScreenshotByHandle

Overwolf APIs / overwolf / overwolf / media / takeWindowsScreenshotByHandle

Call Signature​

function takeWindowsScreenshotByHandle(
windowHandle: number,
postMediaEvent: boolean,
targetFolder: string,
callback: CallbackFunction<FileResult>,
): void;

Takes a window screenshot and calls the callback with the success status and the screenshot URL. The screenshot is saved to the screenshots folder.

Parameters​

ParameterTypeDescription
windowHandlenumberThe window Name
postMediaEventbooleanset true to post media event (onMediaEvent)
targetFolderstringset target folder path to screen shot
callbackCallbackFunction<FileResult>A function called after the screenshot was taken.

Returns​

void

Call Signature​

function takeWindowsScreenshotByHandle(
windowHandle: number,
postMediaEvent: boolean,
callback: CallbackFunction<FileResult>,
): void;

Takes a window screenshot and calls the callback with the success status and the screenshot URL. The screenshot is saved to the screenshots folder.

Parameters​

ParameterTypeDescription
windowHandlenumberThe window Name
postMediaEventbooleanset true to post media event (onMediaEvent)
callbackCallbackFunction<FileResult>A function called after the screenshot was taken.

Returns​

void