<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.ice-online.com/index.php?action=history&amp;feed=atom&amp;title=CALL</id>
	<title>CALL - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.ice-online.com/index.php?action=history&amp;feed=atom&amp;title=CALL"/>
	<link rel="alternate" type="text/html" href="https://wiki.ice-online.com/index.php?title=CALL&amp;action=history"/>
	<updated>2026-04-12T12:25:15Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.34.1</generator>
	<entry>
		<id>https://wiki.ice-online.com/index.php?title=CALL&amp;diff=692&amp;oldid=prev</id>
		<title>ConvertBot: Invoke a macro PROCEDURE or SUBROUTINE</title>
		<link rel="alternate" type="text/html" href="https://wiki.ice-online.com/index.php?title=CALL&amp;diff=692&amp;oldid=prev"/>
		<updated>2020-04-27T22:04:28Z</updated>

		<summary type="html">&lt;p&gt;Invoke a macro PROCEDURE or SUBROUTINE&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;Invoke a macro PROCEDURE or SUBROUTINE&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;NAME&amp;gt;     Procedure or Subroutine to call&lt;br /&gt;
&amp;lt;arg 1:N&amp;gt;  Optional arguments&lt;br /&gt;
&lt;br /&gt;
A macro PROCEDURE or SUBROUTINE is a place to put code that is called frequently&lt;br /&gt;
or a block of code to be executed in its own thread.  Each procedure/subroutine&lt;br /&gt;
begins with&lt;br /&gt;
&lt;br /&gt;
  PROCEDURE &amp;lt;procedure-name&amp;gt; [ &amp;lt;arguments...&amp;gt; ]&lt;br /&gt;
  SUBROUTINE &amp;lt;subroutine-name&amp;gt; [ &amp;lt;arguments...&amp;gt; ]&lt;br /&gt;
&lt;br /&gt;
where the &amp;lt;arguments&amp;gt; are optional.  The procedure ends with the word RETURN.&lt;br /&gt;
The format of the &amp;lt;arguments&amp;gt; is identical to that of the startmacro line of a&lt;br /&gt;
standard macro:  each argument has one letter indicating the type, a colon,&lt;br /&gt;
the argument name, and optionally, a default within square brackets immediately&lt;br /&gt;
following.&lt;br /&gt;
&lt;br /&gt;
A PROCEDURE lives within the context of the current macro sharing all results.&lt;br /&gt;
&lt;br /&gt;
A SUBROUTINE has its own macro context, meaning that its local parameter&lt;br /&gt;
definitions and results, are unique to it.  It cannot see the results from the&lt;br /&gt;
calling macro unless a GLOBAL statement is used within the subroutine.&lt;br /&gt;
&lt;br /&gt;
Examples:&lt;br /&gt;
   The call to the procedure in this example will give a default to the&lt;br /&gt;
   result parameter when called with no argument and override the default&lt;br /&gt;
   parameter value when called with a string argument:&lt;br /&gt;
   &lt;br /&gt;
   !------------------------------------!&lt;br /&gt;
   startmacro&lt;br /&gt;
    call myproc&lt;br /&gt;
    call myproc &amp;quot;newString&amp;quot;&lt;br /&gt;
   endmacro&lt;br /&gt;
   &lt;br /&gt;
   procedure myproc s:stringin[&amp;quot;default&amp;quot;]&lt;br /&gt;
     res stringin   ! This show a value of 'default' for the first call&lt;br /&gt;
                    ! and 'newString for the second call&lt;br /&gt;
   return&lt;br /&gt;
   !------------------------------------!&lt;br /&gt;
 &lt;br /&gt;
Switches:&lt;br /&gt;
  /BG  - execute a SUBROUTINE in a background thread&lt;br /&gt;
&lt;br /&gt;
SEE ALSO:  RETURN, PROCEDURE, SUBROUTINE&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:NXM_Explain]]&lt;/div&gt;</summary>
		<author><name>ConvertBot</name></author>
		
	</entry>
</feed>