PC SOFT

ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Home | Sign in | English EN
This content has been translated automatically. Click here to view the French version.
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
Inserts a token into a "Text token" edit control.
Example
// Clic sur [Insérer le robot de test]
EditInsertToken(SAI_Destinataire, 1, "ROBOT", "robotmail@adresse.test.fr")
// Syntaxe utilisant le type Jeton
MonJeton is Token
MonJeton.DisplayedValue = "ROBOT"
MonJeton.StoredValue = "robotmail@adresse.test.fr"
EditInsertToken(SAI_Destinataire, 1, MonJeton)
Syntax

Inserting a token directly Hide the details

<Result> = EditInsertToken(<Edit control> , <Position> , <Value> [, <Caption>])
<Result>: Integer
  • Real subscript of the inserted token,
  • 0 if an error occurs:
    • If the Edit control is not a "Text token" control (the TokenEnabled property is set to False).
    • If a duplicate was detected and the Property TokenAllowDuplicate is False.
<Edit control>: Control name
Name of the "Text token" edit control.
<Position>: Integer
Token insertion subscript.
  • If <Position> is greater than the number of Token s in the field, the Token is added to the end of the existing Token s (equivalent to the EditAddToken function).
  • If <Position> is set to 0, the token is added at the beginning.
  • If <Position> is -1, <Result> is 0.
<Value>: Character string
Value of the token.
<Caption>: Optional character string
Caption of the token. If this value is not specified, it will correspond to the value of the token.

Inserting a token via the Token type Hide the details

<Result> = EditInsertToken(<Edit control> , <Position> , <Token>)
<Result>: Integer
  • Real subscript of the inserted token,
  • 0 if an error occurs:
    • If the Edit control is not a "Text token" control (the TokenEnabled property is set to False).
    • If a duplicate was detected and the Property TokenAllowDuplicate is False.
<Edit control>: Control name
Name of the "Text token" edit control.
<Position>: Integer
Token insertion subscript.
  • If <Position> is greater than the number of Token s in the field, the Token is added to the end of the existing Token s (equivalent to the EditAddToken function).
  • If <Position> is set to 0, the token is added at the beginning.
  • If <Position> is -1, <Result> is 0.
<Token>: Token variable
Name of the Token variable describing the token to add.
Remarks
  • To add a token at the cursor position, use EditAddToken.
  • The edit control StoredValue property returns the stored values for the tokens, separated by the characters <CR> (Carriage Return).
Related Examples:
The Text token edit control Unit examples (WINDEV): The Text token edit control
[ + ] Using a "Text token" edit control.
The text token edit control Unit examples (WEBDEV): The text token edit control
[ + ] Using a "Text token" edit control.
The Text token edit control Unit examples (WINDEV Mobile): The Text token edit control
[ + ] Using a "Text token" edit control.
Business / UI classification: UI Code
Component: wd270obj.dll
Minimum version required
  • Version 24
This page is also available for…
Comments
Click [Add] to post a comment