ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / WLanguage functions / Controls, pages and windows / Word Processing functions / Types of variables
  • Properties specific to docAutoReplace variables
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
docAutoReplace (Type of variable)
In french: docRemplacementAutomatique
The docAutoReplace type is used to define all the advanced characteristics of a string used to automatically replace another string as the user types in a Word Processing control . The characteristics of this automatic correction can be defined and changed using different WLanguage properties.
Remark: For more details on the declaration of this type of variable and the use of WLanguage properties, see Declaring a variable.
Example
c is docAutoReplace
c.NewString = "10 times faster"
WP_MySalesDoc.AutoCorrect.Replace["10f"] = c

// Alternative syntax (without using the docAutoReplace variable)
WP_MySalesDoc.AutoCorrect.Replace["20f"] = "20 times faster"
d is Document
DocInsert(d, 1, "Hello")

WP_MySalesDoc.AutoCorrect.Replace["bb"] = d

d2 is Document 
d2 <- WP_MySalesDoc.AutoCorrect.Replace["bb"]..NewFormattedString
Properties

Properties specific to docAutoReplace variables

The following properties can be used to handle docAutoReplace variables:
Property nameType usedEffect
NewStringCharacter stringString containing the correction.
Remark: The NewString property takes precedence over the NewFormattedString property (if it exists).
NewFormattedStringDocumentNew string, as a document that can contain formatting.
Remark: This property can also correspond to a variable of type docParagraph, docElement, ...
Minimum version required
  • Version 28
Comments
Click [Add] to post a comment

Last update: 03/01/2023

Send a report | Local help