Click or drag to resize

RuntimeClientRunScriptAsync Method

Version 130.1.90
Runs script with given id in a given context.

Namespace: CefSharp.DevTools.Runtime
Assembly: CefSharp.Core (in CefSharp.Core.dll) Version: 129.0.110.0
Syntax
public Task<RunScriptResponse> RunScriptAsync(
	string scriptId,
	int? executionContextId = null,
	string objectGroup = null,
	bool? silent = null,
	bool? includeCommandLineAPI = null,
	bool? returnByValue = null,
	bool? generatePreview = null,
	bool? awaitPromise = null
)

Parameters

scriptId  String
Id of the script to run.
executionContextId  NullableInt32  (Optional)
Specifies in which execution context to perform script run. If the parameter is omitted theevaluation will be performed in the context of the inspected page.
objectGroup  String  (Optional)
Symbolic group name that can be used to release multiple objects.
silent  NullableBoolean  (Optional)
In silent mode exceptions thrown during evaluation are not reported and do not pauseexecution. Overrides `setPauseOnException` state.
includeCommandLineAPI  NullableBoolean  (Optional)
Determines whether Command Line API should be available during the evaluation.
returnByValue  NullableBoolean  (Optional)
Whether the result is expected to be a JSON object which should be sent by value.
generatePreview  NullableBoolean  (Optional)
Whether preview should be generated for the result.
awaitPromise  NullableBoolean  (Optional)
Whether execution should `await` for resulting value and return once awaited promise isresolved.

Return Value

TaskRunScriptResponse
returns System.Threading.Tasks.Task<RunScriptResponse>
See Also