Cursor (Recordset function): Difference between revisions

From m204wiki
Jump to navigation Jump to search
m (Created page with "<span class="pageSubtitle"><section begin=dpl_desc/><section end=dpl_desc/></span> Cursor constructor <p> <var>Cursor</var> is a member of the <var...")
 
m (Created page with "<span class="pageSubtitle"><section begin=dpl_desc/><section end=dpl_desc/></span> Cursor constructor <p> <var>Cursor</var> is a member of the <var...")
Line 1: Line 1:
<span class="pageSubtitle"><section begin=dpl_desc/><section end=dpl_desc/></span>
{{Template:Recordset:Cursor subtitle}}
[[Category:Recordset methods|Cursor constructor]]
<p>
<var>Cursor</var> is a member of the <var>[[Recordset class|Recordset]]</var> class.
</p>


Instantiates a <var>[[RecordsetCursor class|RecordSetCursor]]</var> object for a
Instantiates a <var>[[RecordsetCursor class|RecordSetCursor]]</var> object for a
particular instance of a <var>Recordset</var> object.
particular instance of a <var>Recordset</var> object.
==Syntax==
==Syntax==
<p class="syntax">%rscursor = %rs:Cursor([LoopLockStrength=lockstrength])
{{Template:Recordset:Cursor syntax}}
</p>
===Syntax terms===
===Syntax Terms===
<table class="syntaxTable">
<table class="syntaxTable">
<tr><th>%rscursor</th>
<tr><th>%rscursor</th>
Line 22: Line 17:


</td></tr></table>
</td></tr></table>
==Usage Notes==
==Usage notes==
<ul>
<ul>
<li>You can have as many cursors as you want for a record set.
<li>You can have as many cursors as you want for a record set.
Line 30: Line 25:
positioned on the first record in the set.
positioned on the first record in the set.
</ul>
</ul>
==See also==
{{Template:Recordset:Cursor footer}}

Revision as of 19:33, 15 April 2011

Create a RecordsetCursor object from a Recordset (Recordset class)


Instantiates a RecordSetCursor object for a particular instance of a Recordset object.

Syntax

%recordsetCursor = recordset:Cursor[( [LoopLockStrength= lockStrength])]

Syntax terms

%rscursor A declared RecordsetCursor object, to which Cursor returns an instance of a RecordsetCursor object, if %rs has at least one record. If %rs has no records, Cursor returns a Null object.
%rs A reference to an instance of a Recordset object.
LoopLockStrength=lockstrength The lock strength to be used for For Record At loops on the cursor. This is an optional, name required, parameter, available in Sirius Mods 7.0 and later. It defaults to None. See "LoopLockStrength for RecordsetCursors".

Usage notes

  • You can have as many cursors as you want for a record set.
  • To test for an empty record set, use IsEmpty, which is much more efficient than testing the record Count for 0,
  • The instantiated RecordsetCursor is automatically positioned on the first record in the set.

See also