Difference between revisions of "DIE()"

From Lianjapedia
Jump to: navigation, search
Line 1: Line 1:
 
==Purpose==
 
==Purpose==
 
Terminate session returning a message or status code
 
Terminate session returning a message or status code
 
  
 
==Syntax==
 
==Syntax==
 
DIE(<expC>|<expN>)
 
DIE(<expC>|<expN>)
 
  
 
==See Also==
 
==See Also==
 
[[CLOSE]], [[ERRORLEVEL()]], [[EXIT()]], [[QUIT]], [[RUN]]
 
[[CLOSE]], [[ERRORLEVEL()]], [[EXIT()]], [[QUIT]], [[RUN]]
 
  
 
==Description==
 
==Description==
 
The DIE() function closes all open files and ends the Lianja process, returns the specified message, <expC>, or status code (-1 to 254), <expN>, to the operating system or calling script.   
 
The DIE() function closes all open files and ends the Lianja process, returns the specified message, <expC>, or status code (-1 to 254), <expN>, to the operating system or calling script.   
 
  
 
==Example==
 
==Example==
Line 22: Line 18:
 
endif
 
endif
 
</code>
 
</code>
 
  
 
==Products==
 
==Products==

Revision as of 11:53, 11 December 2012

Purpose

Terminate session returning a message or status code

Syntax

DIE(<expC>|<expN>)

See Also

CLOSE, ERRORLEVEL(), EXIT(), QUIT, RUN

Description

The DIE() function closes all open files and ends the Lianja process, returns the specified message, <expC>, or status code (-1 to 254), <expN>, to the operating system or calling script.

Example

// Exit if [ABANDON] was pressed
if lastkey()=ctrl('g')
    die("User "+user()+ " exited at "+time())
endif

Products

Lianja, Lianja Server