GetFieldsUpdatedThisEntireAction

Description

Returns a FieldInfo object for each field that was modified by the entire action, including changes made in any initialization hooks. The GetFieldsUpdatedThisEntireAction method (new in version 2003.03.15) resolves an issue with the logic used for determining which fields have changed during an action.

This method reports the fields that changed during the entire action, including all fields that changed before the call to BuildEntity or EditEntity returns. Fields that were implicitly changed during the action's initialization (which includes FIELD_DEFAULT_VALUE hooks setting initial default field values) are reported; fields that were modified by hooks during the initialization of the action are also reported. This method reports fields that were changed by hooks after the initialization phase of the action; see the Rational ClearQuest Designer documentation for the timing and execution order of hooks.

Remarque : This method became available in version 2003.06.13.

Syntaxe

VBScript

entity.GetFieldsUpdatedThisEntireAction 

Perl

$entity->GetFieldsUpdatedThisEntireAction(); 
Identificateur
Description
entity
Objet Entity représentant un enregistrement de données utilisateur. Si vous omettez cette partie de la syntaxe au sein d'un point d'ancrage, l'objet Entity correspondant à l'enregistrement de données en cours est faux (VBScript uniquement).
Valeur de retour
For VBScript, a Variant containing an Array of FieldInfo Objects is returned. Each FieldInfo object corresponds to a field of the Entity object whose value was changed since the most recent action was initiated. If no fields were updated, this method returns an Empty Variant. For Perl, a FieldInfos Object collection is returned.

Exemples

VBScript

DIM CQFieldInfo
DIM CQFieldInfos
DIM sessionObj
set sessionObj = GetSession
' Report any fields that changed during the recent action
CQFieldInfos = CQEntity.GetFieldsUpdatedThisEntireAction
' Get the list of field names returned by this function ...
For Each CQFieldInfo In CQFieldInfos
' Report the fields to the user
   sessionObj.OutputDebugString "Field " & CQFieldInfo.GetName & " changed."
Next

Perl

my(@ActualUpdatedFields);
my($CQFieldInfos);
my($CQEntity);
# Report any fields that changed during the recent action
$CQFieldInfos = $CQEntity->GetFieldsUpdatedThisEntireAction();
# Get the list of field names returned by this function ...
@ActualUpdatedFields = &GetFieldNames($CQFieldInfos);

Commentaires