Tuesday October 29, 2024

       
      SteelArrow Basics
      SteelArrow Tags
  SteelArrow Functions
  SteelArrow Objects
  Advanced Topics
  WAS Overview
   
   
       
      Overview
  Code Samples
  Site Search
   
   
   


Get SteelArrow!     
  <SAFUNCTION>    
 
 
 
Return to Tag List
 
The FUNCTION tag is used to create functions. These functions must exist in one of two places. They can either exist in the server "Functions.aro" file, or within the curent executing script.

Functions have access to all of the currently defined variables and may also receive variables passed with the use of the PARAM tag.

To call a function, the IMPORT tag is used.

 
Attributes:
NAMEliteral string (function name)

 
The following is an example of FUNCTION;
 
<SAFUNCTION NAME="Sum">
   <SARETURN VALUE=PARAM.val1 + PARAM.val2>
</SAFUNCTION>

<SAIMPORT FUNCTION="Sum" NAME=returnValue>
   <SAPARAM NAME=val1 VALUE=10>
   <SAPARAM NAME=val2 VALUE=22>
</SAIMPORT>

<!--- Outputs: 32 --->
<SAOUTPUT VALUE=returnValue>





Copyright © 1998-2004 Tomahawk Technologies Inc.
Privacy Policy