Click or drag to resize

IFrameExecuteJavaScript Method (String, Boolean)

Asynchronously executes JavaScript code using the current context.

Namespace:  DotNetBrowser.Frames
Assembly:  DotNetBrowser (in DotNetBrowser.dll) Version: 2.23.2
Syntax
C#
Task<Object> ExecuteJavaScript(
	string javaScript,
	bool userGesture = false
)

Parameters

javaScript
Type: SystemString
The JavaScript code to execute.
userGesture (Optional)
Type: SystemBoolean
Indicates whether JavaScript is initiated by a user gesture.

Return Value

Type: TaskObject
The task that can be used to wait for completion and obtain the result of the JavaScript execution.
Exceptions
ExceptionCondition
ObjectDisposedExceptionThe IFrame object has already been disposed.
ArgumentException The javaScript is null, empty, or contains only blank characters.
See Also