setglobal
Syntax: %setglobal(name,value)
set the value of the global variable name (stored in the INI file). A variable stored with %setglobal can only be retreived using %getglobal and has no relationship with other variables stored in your package files. The data is not actually written to the INI file on disk until CMUD exits, so data can be lost if CMUD crashes. The #SAVE command can be used to force the INI file contents to be saved.
setglobal Example:
#CALL %setglobal("MyName","Zugg")
#SHOW %getglobal("MyName")
Displays: "Zugg"
After exiting CMUD, if you inspect the contents of the CMUD.INI file, you will find the following data:
[User]
MyName=Zugg |