VARINFO()

From Recital Documentation Wiki
Jump to: navigation, search

Purpose

Function to return scope information about a memory variable or array


Syntax

VARINFO(<expC>)


See Also

DECLARE, DIMENSION, DO, DISPLAY MEMORY, LOCAL, NAMESPACE, NAMESPACE(), PARAMETERS, PRIVATE, PUBLIC, SET CLIPPER, SET STRICT, STORE


Description

The VARINFO() function returns scope information about a memory variable or array. The memory variable or array name is specified in the character string <expC>. For public variables and arrays, VARINFO() returns the character string "Public". For private and local variables and arrays, VARINFO() returns the character string "Private " followed by the name of the declaring procedure, function or program. Program names are in mixed case and include the full path and file extension. Procedure and function names are returned in upper case.


Example

function func1
public m_var1
private m_var2
? "m_var1 " + varinfo("m_var1")
? "m_var2 " + varinfo("m_var2")
?
endfunc
 
func1()
m_var1 Public                                                                   
m_var2 Private (FUNC1) 

Products

Recital, Recital Server