$ListNewI: Difference between revisions

From m204wiki
Jump to navigation Jump to search
mNo edit summary
m (add link)
 
(45 intermediate revisions by 3 users not shown)
Line 2: Line 2:
<span class="pageSubtitle">Create empty $list associated with image</span>
<span class="pageSubtitle">Create empty $list associated with image</span>


<p class="warning">Most Sirius $functions have been deprecated in favor of Object Oriented methods. The OO equivalent for the $ListNewI function is the [[New (Stringlist constructor)]].</p>
<p class="warn"><b>Note:</b> Many $functions have been deprecated in favor of Object Oriented methods. The OO equivalent for the <var>$ListNewI</var> function is the <var>[[New (Stringlist constructor)|New]]</var> constructor. </p>


This function creates an empty $list. The created $list is associated with an image exactly as if the [[$ListNew]] call was followed by a [[$ListImg]] call.  
<var>$ListNewI</var> creates an empty [[$lists|$list]]. The created $list is associated with an [[Images|image]] exactly as if the <var>[[$ListNew]]</var> call was followed by a <var>[[$ListImg]]</var> call.  


The $ListNewI function accepts two arguments and returns a numeric result.  
The <var>$ListNewI</var> function accepts two arguments and returns a numeric result.  


The first argument can either be a string containing the name of an image or any image item from the required image. This is a required argument.
==Syntax==
<p class="syntax"><span class="term">%result</span> = <span class="literal">$ListNewI</span>(<span class="term">image_id</span>, [<span class="term">option</span>])
</p>


The second argument, if set to the string <tt>NOREL</tt>, indicates that the contents of the $list are not to be emptied when a RELEASE ALL RECORDS statement is executed. This is an optional argument.
<table>
<tr><th>%result</th>
<td>A numeric variable set to the identifier of the created empty $list.
<p>No error codes are associated with <var>$ListNewI</var>, though the absence of the image identifier or an invalid image identifier will cause request cancellation. </p></td></tr>


==Syntax==
<tr><th>image_id</th>  
<p class="syntax"><section begin="syntax" /> %RESULT = $ListNewI(image_id, option)
<td>A string that contains the name of an image, or the name of any image item from the required image. </td></tr>
<section end="syntax" /></p>
<p class="caption">$ListNewI Function
</p>
<p class="caption">%RESULT is set to the identifier of the created empty $list.</p>
There are no error codes associated with $ListNewI though the absence of the image identifier or an invalid image identifier will cause request cancellation.


All invocations of a particular call to $ListNewI will always return the same value. Each time that call is executed, any previous $list created by that call is deleted, and a new list is created.  
<tr><th>option</th>
<td>Specifying the string <code>NOREL</code> indicates that the contents of the $list are not to be emptied when a <var>Release All Records</var> statement is executed. </td></tr>
</table>


$ListNewI is available in Version 6.2 and later of the ''[[Sirius Mods]]''.<p>
==Usage notes==
All invocations of a particular call to <var>$ListNewI</var> will always return the same value. Each time that call is executed, any previous $list created by that call is deleted, and a new list is created.  


==Products authorizing {{PAGENAMEE}}==
<ul class="smallAndTightList">
<ul class="smallAndTightList">
<li>[[Sirius functions]]</li>
<li>[[Sirius Functions]]</li>
<li>[[Fast/Unload User Language Interface]]</li>
<li>[[Fast/Unload User Language Interface]]</li>
<li>[[Janus Open Client]]</li>
<li>[[Media:JoclrNew.pdf|Janus Open Client]]</li>
<li>[[Janus Open Server]]</li>
<li>[[Media:JosrvrNew.pdf|Janus Open Server]]</li>
<li>[[Janus Sockets]]</li>
<li>[[Janus Sockets]]</li>
<li>[[Janus Web Server]]</li>
<li>[[Janus Web Server]]</li>
<li>[[Japanese functions]]</li>
<li>Japanese functions</li>
<li>[[Sir2000 Field Migration Facility]]</li>
<li>[[Media:SirfieldNew.pdf|Sir2000 Field Migration Facility]]</li>
 
</ul>
</ul>
   
   
</p>
<p class="caption">Products authorizing $ListNewI
</p>
[[Category:$Functions|$ListNewI]]
[[Category:$Functions|$ListNewI]]

Latest revision as of 21:43, 13 June 2018

Create empty $list associated with image

Note: Many $functions have been deprecated in favor of Object Oriented methods. The OO equivalent for the $ListNewI function is the New constructor.

$ListNewI creates an empty $list. The created $list is associated with an image exactly as if the $ListNew call was followed by a $ListImg call.

The $ListNewI function accepts two arguments and returns a numeric result.

Syntax

%result = $ListNewI(image_id, [option])

%result A numeric variable set to the identifier of the created empty $list.

No error codes are associated with $ListNewI, though the absence of the image identifier or an invalid image identifier will cause request cancellation.

image_id A string that contains the name of an image, or the name of any image item from the required image.
option Specifying the string NOREL indicates that the contents of the $list are not to be emptied when a Release All Records statement is executed.

Usage notes

All invocations of a particular call to $ListNewI will always return the same value. Each time that call is executed, any previous $list created by that call is deleted, and a new list is created.

Products authorizing $ListNewI