4D Write v16WR Get selected text |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
4D Write v16
WR Get selected text
|
WR Get selected text ( area ) -> Function result | ||||||||
Parameter | Type | Description | ||||||
area | Longint |
![]() |
4D Write area | |||||
Function result | Text |
![]() |
Text selected in area | |||||
The WR Get selected text command returns the selected text in area.
If your database is not running in Unicode mode but in ASCII compatibility mode (former version 4D databases that are converted without the "Unicode Mode" preference being selected), the text returned will only contain the first 32,000 characters.
The following example places the selected text in area into the variable vText.
vText:=WR Get selected text(area)
Your database was created with a former version of 4D and it was not configured in Unicode mode. You want to test the case where you have selected more than 32,000 characters:
C_LONGINT($start;$end)
C_TEXT($text)
WR GET SELECTION(WritePicture;$start;$end) `Recovery of selection limits
If($end-$start>=32000) `If the difference is greater than or equal to 32,000, the selection returned will be truncated
ALERT("Only the first 32,000 characters will be recovered.")
End if
$text:=WR Get selected text(WritePicture)
Product: 4D Write
Theme: WR Text Manipulation
Number:
89191
Modified: 4D Write v11
4D Write Language ( 4D Write v16)