Aller au contenu principal
Version: Next

VP Get table dirty rows

Historique
ReleaseModifications
19 R8Ajout

VP Get table dirty rows ( vpAreaName : Text ; tableName : Text { ; reset : Boolean {; sheet : Integer }} ) : Collection

ParamètresTypeDescription
vpAreaNameText->Nom d'objet formulaire zone 4D View Pro
tableNameText->Nom de table
resetBoolean->True to clear the dirty status from the current table, False to keep it untouched. Default=True
sheetInteger->Numéro d'indice de la feuille (feuille courante si omis)
RésultatCollection<-Collection of objects with all the items modified since the last reset

Description

The VP Get table dirty rows command returns a collection of dirty row objects, containing items that were modified since the last reset in the specified tableName.

In vpAreaName, pass the name of the 4D View Pro area.

In tableName, pass the name of the table for which you want to get the dirty rows. Only modified columns bound to a data context will be taken into account.

By default, calling the command will clear the dirty status from the current table. To keep this status untouched, pass False in the reset parameter.

In sheet, pass the index of the target sheet. Si aucun numéro n'est spécifié ou si vous passez -1, la commande s'applique à la feuille courante.

La numérotation démarre à 0.

Each dirty row object in the returned collection contains the following properties:

PropriétéTypeDescription
itemobjectObjet modifié de la ligne modifiée
originalItemobjectObjet avant modification
rowintegerIndex de la ligne modifiée

If tableName is not found or if it does not contain a modified column, the command returns an empty collection.

Exemple

Vous souhaitez compter le nombre de lignes éditées :

var $dirty : Collection
$dirty:=VP Get table dirty rows("ViewProArea"; "ContextTable"; False)
VP SET NUM VALUE(VP Cell("ViewProArea"; 0; 0); $dirty.length)

Voir également

VP CREATE TABLE
VP Find table
VP SET TABLE COLUMN ATTRIBUTES
VP RESIZE TABLE