ToString (Recordset function): Difference between revisions

From m204wiki
Jump to navigation Jump to search
m (Created page with "{{Template:Recordset:ToString subtitle}} <var>ToString</var> returns to a lonstring the contents of the <var>Recordset</var> object. ==Syntax== {{Template:Recordset:ToString s...")
 
mNo edit summary
Line 1: Line 1:
{{Template:Recordset:ToString subtitle}}
{{Template:Recordset:ToString subtitle}}
<var>ToString</var> returns to a lonstring the contents of the <var>Recordset</var> object.   
<var>ToString</var> returns to a longstring information (count, lock strength, file, record numbers) about the contents of the <var>Recordset</var> object.   


==Syntax==
==Syntax==
Line 22: Line 22:
==Examples==
==Examples==


The following record display is produced by a <code>print %recset</code>
The following record display is produced by a <code>print %recset</code> statement.
statement.  The output line wrapping is altered for display purposes.
<p class="output">LockStrength=Share, Count=5, Records=(MYFILE: 0,1,2,3,4)
<p class="output">
</p>
</p>


==See also==
==See also==
{{Template:Recordset:ToString footer}}
{{Template:Recordset:ToString footer}}

Revision as of 19:17, 15 April 2011

Information about Recordset (Recordset class)

ToString returns to a longstring information (count, lock strength, file, record numbers) about the contents of the Recordset object.

Syntax

%string = recordset:ToString[( [MaxRecords= number])]

Syntax terms

%string A longstring variable to receive the contents of the Recordset.
recordset A Recordset object variable.
MaxRecords This NameRequired argument is a numeric value that specifies an upper limit on the number of records to be included in the returned data. MaxRecords is an optional argument that defaults to ??.

Usage notes

  • ToString can be applied implicitly: simply Print (or Audit) an object variable, and the ToString method is automatically applied to the object. That is:

    print %recset

    is equivalent to:

    print %recset:ToString

Examples

The following record display is produced by a print %recset statement.

LockStrength=Share, Count=5, Records=(MYFILE: 0,1,2,3,4)

See also