Programmer Guide/Command Reference/ATTRIBUTES: Difference between revisions
From STX Wiki
Jump to navigationJump to search
No edit summary |
No edit summary |
||
Line 16: | Line 16: | ||
delete /Var #table | delete /Var #table | ||
See example script <code>scripts\examples\reflection.sts</code> demonstrates the use of the ATTRIBUTES command and some other possibilities to retrieve attributes and properties of shell items. | See also: The example script <code>scripts\examples\reflection.sts</code> demonstrates the use of the ATTRIBUTES command and some other possibilities to retrieve attributes and properties of shell items. | ||
<!-- C.G. 11.3.2011 --> | <!-- C.G. 11.3.2011 --> |
Revision as of 09:46, 23 March 2011
Overview
The ATTRIBUTES
command retrieves a blank-separated list of attributes of a shell item, or of variables available in a given context.
Usage
#list := ATTRIBUTES item|MACRO|SHELL|GLOBAL
- returns the blank-separated list of all available attributes for the supplied shell item item or a list of variables available:
- in the current macro, if
ATTRIBUTES MACRO
is used; - in the current shell, if
ATTRIBUTES SHELL
is used; - globally, if
ATTRIBUTES GLOBAL
is used.
- in the current macro, if
Example
#table := new table * #list := ATTRIBUTES $#table um 'The item attributes available for a table item are: $#list' delete /Var #table
See also: The example script scripts\examples\reflection.sts
demonstrates the use of the ATTRIBUTES command and some other possibilities to retrieve attributes and properties of shell items.