WordWrap. RpvCorporate.ocx control.
Use this function to split a long line
into shorter lines.
Syntax:
WordWrap(InputStr, MaxLength, FontName, FontSize, FontBold, LineNumber)
"InputStr" is the long line that you want
to split.
"MaxLength" is the maximum width of a line expressed in twips.
"LineNumber" indicates which line of the divided text we need to obtain. If
"LineNumber" is 0 (zero), function returns total of divided lines.
For the "FontBold" parameter, 0 means normal and 1 means bold.
Example:
Rpv1.WordWrap(MyLongLine, 10000, "arial", 12, 0, 2)
This example will show the line number two (supposing that we are obtaining more
than one line).
This function will return the indicated line (LineNumber) of the divided text.
If "LineNumber" is zero, WordWrap will return the total of lines.
VB Example:
MyLongLine = "Type any long text here"
For i = 1 to Rpv1.WordWrap(MyLongLine, 8000, "arial", 10, 0, 0)
'zero returns total of lines.
MsgBox Rpv1.WordWrap(MyLongLine, 8000, "arial", 10, 0,
i)
Next i
|