ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

This content has been translated automatically.  Click here  to view the French version.
Help / WLanguage / WLanguage functions / Controls, pages and windows / HTML Editor functions
WINDEV
WindowsLinuxJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac Catalyst
Others
Stored procedures
Searches for a string in an HTML Editor control. The search does not take into account the formatting of the string.
Example
// Compte le nombre de WINDEV
// (y compris si le WIN est en gras)
nbMot is int = 0
HTMLEditorSearch(EDHTML_MonEditeurHTML, "WINDEV",  ...
		EditeurHTMLRecherche_Callback, WholeWord + IgnoreCase)

INTERNAL PROCEDURE EditeurHTMLRecherche_Callback(nPos is int)
	IF nPos = 0 THEN
		// Fin du parcours
		Info("Nombre de WINDEV: " + nbMot)
		RETURN 
	END
	// Trouvé
	nbMot++
END
Syntax
HTMLEditorSearch(<HTML Editor control> , <Text to find> , <WLanguage procedure> [, <Options> [, <Maximum number>]])
<HTML Editor control>: Control name
Name of the HTML Editor control used.
<Text to find>: Character string
Text to search for in the HTML Editor control.
<WLanguage procedure>: Procedure name
WLanguage procedure ("callback") executed for each element found. This procedure has the following format:
PROCEDURE <Nom de la procédure>(nPosition est un entier)
where <nPosition> is an integer that corresponds to the position of the searched text with respect to the text without tags. This value can be used: At the end of the search, <nPos> is set to 0.
<Options>: Optional constant (or combination of constants)
Search options:
IgnoreCaseCase and accent insensitive search (ignores uppercase and lowercase differences).
WholeWordWhole word search (enclosed in punctuation characters or spaces).

By default, the search is case sensitive: the searched text must have the same case as the text to be found.. To perform a case-insensitive search, use the IgnoreCase constant.
<Maximum number>: Optional integer
Maximum number of elements to be found. Limits the search (for example, take into account only the first 5 elements found).
Business / UI classification: UI Code
Component: wd300obj.dll
Minimum version required
  • Version 26
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 09/21/2024

Send a report | Local help