Click or drag to resize

TargetClient.SetAutoAttachAsync Method

Version 118.6.80
Controls whether to automatically attach to new targets which are considered to be related to this one. When turned on, attaches to all existing related targets as well. When turned off, automatically detaches from all currently attached targets. This also clears all targets added by `autoAttachRelated` from the list of targets to watch for creation of related targets.

Namespace:  CefSharp.DevTools.Target
Assembly:  CefSharp.Core (in CefSharp.Core.dll) Version: 118.6.80.0
Syntax
public Task<DevToolsMethodResponse> SetAutoAttachAsync(
	bool autoAttach,
	bool waitForDebuggerOnStart,
	bool? flatten = null,
	IList<TargetFilter> filter = null
)

Parameters

autoAttach
Type: System.Boolean
Whether to auto-attach to related targets.
waitForDebuggerOnStart
Type: System.Boolean
Whether to pause new targets when attaching to them. Use `Runtime.runIfWaitingForDebugger`to run paused targets.
flatten (Optional)
Type: System.Nullable<Boolean>
Enables "flat" access to the session via specifying sessionId attribute in the commands.We plan to make this the default, deprecate non-flattened mode,and eventually retire it. See crbug.com/991325.
filter (Optional)
Type: System.Collections.Generic.IList<TargetFilter>
Only targets matching filter will be attached.

Return Value

Type: Task<DevToolsMethodResponse>
returns System.Threading.Tasks.Task<DevToolsMethodResponse>
See Also