4D Write v14WR GET PARAGRAPHS |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
4D Write v14
WR GET PARAGRAPHS
|
WR GET PARAGRAPHS ( area ; beginPara ; endPara ) | ||||||||
Parameter | Type | Description | ||||||
area | Longint |
![]() |
4D Write area | |||||
beginPara | Longint |
![]() |
Beginning of the paragraph to return | |||||
endPara | Longint |
![]() |
End of the paragraph to return | |||||
The WR GET PARAGRAPHS command returns the position of the first character of the first paragraph of the selection and the position of the carriage return of the last paragraph of the selection, in the 4D Write area referenced by area.
The following example scans the document and retrieves the position of the first and last character for each paragraph.
`Locating the cursor at the beginning of the area
WR SET SELECTION(area;0;0)
`Counting the number of paragraphs in the document
nbPara:=WR Count(Zone;wr nb paragraphs)
`Processing paragraphs one by one
For($i;1;nbPara)
`Retrieving the position of the first and last characters
WR GET PARAGRAPHS(area;begin;Pos)
`Relocating after the last processed paragraph
WR SET SELECTION(area;Pos;Pos)
End for
Product: 4D Write
Theme: WR Text Manipulation
Number:
89464
Created: 4D Write 6.5
4D Write Language ( 4D Write v11.6)
4D Write Language ( 4D Write v12)
4D Write Language ( 4D Write v14)
4D Write Language ( 4D v13)
4D Write Language ( 4D Write v14 R2)
4D Write Language ( 4D Write v14 R3)
4D Write Language ( 4D Write v14 R4)