Syntax: @attrvals(attribute_pattern_list[, name_pattern_list, attribute_search_options])
Argument1: pattern string list, attribute_pattern_list
Argument2: pattern string list, name_pattern_list
Argument3: int, attribute_search_options
The attribute_search_options is an integer value indicating how a “*” in the attribute_pattern should be treated when matching. Use “0” to treat “*” as a wildcard and “1” to treat “*” as a literal. The default is “0”.
Return: string list
Returns a string list of all attribute values of the current workfile page that satisfy the attribute_pattern_list and, optionally, the object name_pattern_list. The attribute_pattern_list may be made up of any number of “?” (indicates any single character) or “*” (indicates any number of characters).
Examples
If a workfile contains three objects named “GDP”, “UNEMP”, and “INFLATION”, each object contained a “month” attribute where the GDP “month” values was “Jan”, the UNEMP value was “Feb”, and the INFLATION value was “Mar”, then
@attrvals("M*")
return the string list “Mar”. All attributes values for all objects in the workfile that begin with “M” are included. Alternatively,
@attrvals("M* D*", “GDP”)
returns the list of attribute values for the object GDP that begin with “M” and “S”.
If a fourth object INTEREST had an attribute value “*Mar” for “month,” the command
@attrvals("*mar", “*”)
will return “*mar mar”. This is because the “*” in “*mar” is treated as a wildcard and the value “Mar” from INFLATION and value “*Mar” from INTEREST match. However, the command
@attrvals("*mar", “*”,1)
will only return “*mar”, since the “*” in “*Mar” is treated as a literal and only “*Mar” from INTEREST matches.