Version

xamGantt - Replay-Only Methods

Topic Overview

Purpose

This topic provides information about the xamGantt™ control’s testable user replay-only methods.

xamGantt Test Object Replay-Only Methods

Replay-Only methods summary chart

The following table briefly explains the replay-only methods for testing controls. Detailed information about the methods follows the table.

Method Description

This method returns the supplied task’s property value.

This method sets the supplied task’s property value.

This method sets the visible date of the task.

GetTaskProperty

Description

The GetTaskProperty method retrieves a task’s value.

Parameters

The following table lists the code examples included in this topic.

Method parameter Description

oTaskArg

Validates the task’s value property.

oPropertyName

Returns the supplied task’s name property.

Example

Retrieves and displays the third (index=2) visible task name in a message box.

msgbox …XamGantt("Identifier").GetTaskProperty(2, gntTaskName)

Possible exceptions

The following list contains the possible exceptions for the method and the reason that is likely to be causing them.

  • The specified project task index [{1}] is out of range

  • The specified project task index[{1}] was not found

SetTaskProperty

Description

The SetTaskProperty method allows changing a task’s value with a specified string value.

Parameters

The following table lists the code examples included in this topic.

Method parameter Description

oTaskArg

Validates the task’s value property.

oPropertyName

Validates the task’s name property.

oNewValue

Attempts to set the task’s value property to a new value.

Example

Changing the task named “Planning” to a name “New name”.

XamGantt("Identifier").SetTaskProperty “Planning”, gntTaskName, “New name”

Possible exceptions

The following list contains the possible exceptions for the method and the reason that is likely to be causing them.

  • The specified project Task index [{1}] is out of range

  • Cannot find the following project task [{1}]

SetFirstVisibleDate

Description

This method allows setting the first visible date to a task where the first date increment includes the supplied date.

Parameters

The following table explains the method’s parameter followed by code example.

Method parameter Description

dtNewDate

An argument containing the new supplied date for a given task.

Example

Set the first visible DateTime to one where the first date increment includes 9/14/2012 8:00AM.

XamGantt("Identifier").SetFirstVisibleDate  #9/14/2012 8:00AM#

Possible exceptions

None (outside of invalid or not included parameters thrown by UFT).

Related Content

Topics

The following topics provide additional information related to this topic.

Topic Purpose

This topic provides information about the xamGantt control’s testable user actions and elements.

This topic provides information about the xamGantt control’s testable user recordable methods.