Tests Property (ATask)

Returns a descendent test/task object of this task as specified by the vKey (index or ID) parameter.

Syntax

[ obTaskOrTest = ] Object.Tests ( vKey )

The Tests property syntax has the following parts:

 

Name

Type

Description

Object

ATask

ATask object

vKey

Variant

The parameter which specifies the ATask object. This can be a number (zero based index) or a string (task or test ID).

obTaskOrTest

Object

A descendent test/task object of this Task as specified by the vKey parameter.

Comments

If vkKey specifies a number, the return value is a direct child of this task object. If a string is specified, the return object can be any  descendent test/task object of this task.

Use the IsTask property to determine whether the return object is a Task or is a Test.

Example

The following statements retrieve a direct child Test/Task object of this Task as specified by the vKey parameter:

obTest = Task.Tests(5)

or

obTest = Task.Tests("_5VDCTest")

Applies to

ATask

See Also

IsTask (ATask), IsTask (ATest), TestsCount