Difference between revisions of "MEMOLINE()"
Yvonne.milne (Talk | contribs) m (1 revision) |
Yvonne.milne (Talk | contribs) |
||
Line 1: | Line 1: | ||
==Purpose== | ==Purpose== | ||
Function to extract a line of text from a memo field | Function to extract a line of text from a memo field | ||
− | |||
==Syntax== | ==Syntax== | ||
MEMOLINE(<memofield>, <expN1>, <expN2>[,<expN3>,<expL>]) | MEMOLINE(<memofield>, <expN1>, <expN2>[,<expN3>,<expL>]) | ||
− | |||
==See Also== | ==See Also== | ||
− | + | [[MEMLINES()]], [[MEMOEDIT()]], [[MEMOREAD()]], [[MEMOTRAN()]], [[MEMOWRITE()]], [[MLCOUNT()]], [[MLINE()]], [[SET MEMOWIDTH]] | |
− | + | ||
==Description== | ==Description== | ||
Line 15: | Line 12: | ||
The length of the line extracted is not affected by the SET MEMOWIDTH command. | The length of the line extracted is not affected by the SET MEMOWIDTH command. | ||
− | |||
==Example== | ==Example== | ||
<code lang="recital"> | <code lang="recital"> | ||
use prospect | use prospect | ||
− | |||
− | |||
m_last = memlines(comp_hist) | m_last = memlines(comp_hist) | ||
for n=1 to m->m_last | for n=1 to m->m_last | ||
Line 27: | Line 21: | ||
? m_line | ? m_line | ||
next | next | ||
− | |||
clear | clear | ||
</code> | </code> | ||
− | |||
− | |||
− | |||
[[Category:Documentation]] | [[Category:Documentation]] | ||
[[Category:Functions]] | [[Category:Functions]] | ||
[[Category:Memos]] | [[Category:Memos]] | ||
[[Category:Memos Functions]] | [[Category:Memos Functions]] |
Revision as of 05:02, 10 February 2012
Contents
Purpose
Function to extract a line of text from a memo field
Syntax
MEMOLINE(<memofield>, <expN1>, <expN2>[,<expN3>,<expL>])
See Also
MEMLINES(), MEMOEDIT(), MEMOREAD(), MEMOTRAN(), MEMOWRITE(), MLCOUNT(), MLINE(), SET MEMOWIDTH
Description
The MEMOLINE() function extracts a formatted line of text from the specified <memofield>. The <expN1> is the number of characters per line and <expN2> is the line number to extract. The <expN3> is included for compatibility with the Clipper tab size setting, but its value is ignored. The <expL> determines whether word wrapping is on or off. If <expL> is .T. (True), and the line length indicated by <expN1> falls in the middle of a word, that word will not be returned until the next line is extracted. If <expL> is .F. (False), the number of characters specified by <expN1> is returned. The default setting of <expL> is .T. (True).
The length of the line extracted is not affected by the SET MEMOWIDTH command.
Example
use prospect m_last = memlines(comp_hist) for n=1 to m->m_last m_line = memoline(comp_hist,40,m->n) ? m_line next clear