RanorexRanorex Documentation
TryFindSingle<(Of <(T>)>) Method (path, timeout, foundAdapter)
NamespacesRanorexAdapterTryFindSingle<(Of <(T>)>)(RxPath, Duration, T%)
Tries to apply a Ranorex Path to the adapter, returning a specific adapter type (e.g. Role or Capability).
Declaration Syntax
C#Visual BasicVisual C++
public bool TryFindSingle<T>(
	RxPath path,
	Duration timeout,
	out T foundAdapter
)
where T : Adapter
Public Function TryFindSingle(Of T As Adapter) ( _
	path As RxPath, _
	timeout As Duration, _
	<OutAttribute> ByRef foundAdapter As T _
) As Boolean
public:
generic<typename T>
where T : Adapter
bool TryFindSingle(
	RxPath^ path, 
	Duration^ timeout, 
	[OutAttribute] T% foundAdapter
)
Generic Template Parameters
T
The expected adapter type. The supplied type must inherit from Adapter, but most not be the Adapter type itself.
Parameters
path (RxPath)
The RxPath to apply.
timeout (Duration)
The time to keep looking for the element.
foundAdapter ( T %)
The first element found converted to the specified adapter type or null if no element is found within the timeout or the element does not support the capabilities to create the specified adapter type.
Return Value
True if an element is found for the specified path within the specified timeout and the specified adapter type could be created, otherwise false.

Assembly: Ranorex.Core (Module: Ranorex.Core) Version: 4.0.3.22982 (4.0.3.22982)