PC SOFT

ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Home | Sign in | English EN
  • Use conditions
  • Adding an empty row
  • Characteristics of the row
  • Position of added row
  • Handling a binary memo
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Adds a row at the end of a Looper control.
Remark: It is recommended to use <Looper>.AddLine. <Looper>.AddLine allows you to add:
  • TAB characters into the attributes/controls.
  • all types of values into the attributes/controls.
Versions 15 and later
Android This function is now available for Android applications.
New in version 15
Android This function is now available for Android applications.
Android This function is now available for Android applications.
Versions 17 and later
iPhone/iPad This function is now available for iPhone/iPad applications.
New in version 17
iPhone/iPad This function is now available for iPhone/iPad applications.
iPhone/iPad This function is now available for iPhone/iPad applications.
Versions 21 and later
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
New in version 21
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
Example
// Initialisation du champ Zone répétée ZR_REPETE1
ZR_REPETE1.SupprimeTout()
HLitPremier(Produit, NomProd)
TANTQUE HEnDehors() = Faux
ZR_REPETE1.Ajoute(Produit.NomProd + TAB + Produit.CodeProduit)
HLitSuivant(Produit, NomProd)
FIN
// Ajout d'une répétition vide
ZR_Zone1.Ajoute()
// Positionnement sur la répétition vide
Indice = ZR_Zone1.Occurrence()
// Puis initialisation des attributs
ATT_AttributNom[Indice] = "Hobbes"
ATT_AttributPrénom[Indice] = "Samantha"
 
// Ou initialisation des champs
// ZR_Zone1[Indice].ChampNom = "Hobbes"
// ZR_Zone1[Indice].ChampPrénom = "Samantha"
Syntax

Adding a row to a Looper control with attributes Hide the details

<Result> = <Looper control>.Add([<Value>])
<Result>: Boolean
  • True if the addition was successful,
  • False otherwise.
<Looper control>: Control name
Name of Looper control to use.
<Value>: Optional character string
List of values that will be inserted into the new row. This parameter must have the following format:
<Value 1> + TAB + ... + <Value N>

The different values must be specified in the order of the attributes (Looper control description window).
To specify no value for one of the attributes, use an empty string ("") or 0 (depending on the type of attribute).
An empty row will be added if this parameter corresponds to an empty string ("").
Universal Windows 10 AppAndroidiPhone/iPad

Adding a row to a Looper control without attributes Hide the details

<Result> = <Looper control>.Add()
<Result>: Boolean
  • True if the addition was successful,
  • False otherwise.
<Looper control>: Control name
Name of Looper control to use.
Remarks

Use conditions

<Looper>.Add can be used on a browsing or memory Looper control.

Adding an empty row

Once an empty row was added, each attribute or each control must be initialized one by one.
For example:
  • For a Looper control with attributes:
    // Ajout d'une répétition vide
    ZR_Zone1.Ajoute()
     
    // Positionnement sur la répétition vide
    Indice = ZR_Zone1.Occurrence()
    // Puis initialisation des attributs
    ATT_AttributNom[Indice] = "Hobbes"
    ATT_AttributPrénom[Indice] = "Samantha"
    ATT_AttributCouleurPrénom[Indice] = RougeClair
    ATT_AttributVisibleAdresse[Indice] = Faux
  • For a Looper control without attributes:
    // Ajout d'une répétition vide
    ZR_Zone1.Ajoute()
     
    // Positionnement sur la répétition vide
    Indice = ZR_Zone1.Occurrence()
    // Puis initialisation des champs
    ZR_Zone1[Indice].ChampNom = "Hobbes"
    ZR_Zone1[Indice].ChampPrénom = "Samantha"
    ZR_Zone1[Indice].ChampPrénom.CouleurFond = RougeClair
    ZR_Zone1[Indice].ChampAdresse.Visible = Faux

Characteristics of the row

If a value corresponds to the result of a calculation, the numeric expression must be enclosed in brackets. For example:
ZR_ZoneCalcul.Ajoute((53+29) + TAB + (83-21))

Position of added row

By default, the row is added at the end of the Looper control.
If the Looper control is sorted (<Looper>.Sort), the added row is positioned in the Looper control according to the current sort.

Handling a binary memo

To add a binary memo into a Looper control, use <Looper>.AddLine.
Component: wd270obj.dll
Minimum version required
  • Version 23
This page is also available for…
Comments
Click [Add] to post a comment