Difference between revisions of "ISSET()"

From Recital Documentation Wiki
Jump to: navigation, search
(Class)
Line 1: Line 1:
{{YLM to do}}
 
 
 
 
 
==Purpose==
 
==Purpose==
 
+
Function to check whether a variable exists
  
  
 
==Syntax==
 
==Syntax==
 
+
ISSET(<variable name>)
  
  
 
==See Also==
 
==See Also==
 
+
[[DECLARE]], [[DIMENSION]], [[LOCAL]], [[PARAMETERS]], [[PRIVATE]], [[PUBLIC]], [[RELEASE]], [[STATIC]], [[STORE]], [[TYPE()]], [[UNSET()]]
  
  
 
==Description==
 
==Description==
 
+
The ISSET() function can be used to check whether a variable exists.  ISSET() will return .T. (true) if the variable named <variable name> exists and .F. (false) if it does not exist.  Variables can be formally declared ([[PUBLIC]], [[PRIVATE]] etc.) or automatically created when they are assigned a value.
  
  
 
==Example==
 
==Example==
 
<code lang="recital">
 
<code lang="recital">
 
+
if isset(m_var)
 +
  // m_var exists
 +
endif
 
</code>
 
</code>
  
 
==Products==
 
==Products==
 +
Recital, Recital Server
  
 
[[Category:Documentation]]
 
[[Category:Documentation]]
 
[[Category:Functions]]
 
[[Category:Functions]]
 +
[[Category:Memory Variables]]
 +
[[Category:Memory Variables Functions]]

Revision as of 17:08, 30 October 2009

Purpose

Function to check whether a variable exists


Syntax

ISSET(<variable name>)


See Also

DECLARE, DIMENSION, LOCAL, PARAMETERS, PRIVATE, PUBLIC, RELEASE, STATIC, STORE, TYPE(), UNSET()


Description

The ISSET() function can be used to check whether a variable exists. ISSET() will return .T. (true) if the variable named <variable name> exists and .F. (false) if it does not exist. Variables can be formally declared (PUBLIC, PRIVATE etc.) or automatically created when they are assigned a value.


Example

if isset(m_var)
  // m_var exists
endif

Products

Recital, Recital Server