GetAliasList
Script function

world.GetAliasList

DOC_scripting Read about scripting

Type

Method

Summary

Gets the list of aliases

Prototype

VARIANT GetAliasList();

DOC_data_types View list of data type meanings


Description

Returns an array of all the named aliases currently defined. You can then use GetAlias or GetAliasInfo for more details about each one.

Note - from version 3.40 onwards GetAliasList returns all aliases, even unlabelled ones. The unlabelled aliases will have assigned an "internal" label (like "*alias42") that can be used in GetAliasInfo, and similar routines.



VBscript example

dim alList

alList = world.GetAliasList

If Not IsEmpty (alList) then

  For Each name In alList 
    world.Note name
  Next

End If



Jscript example

aliaslist = new VBArray(world.GetAliasList()).toArray();

if (aliaslist)  // if not empty
 for (i = 0; i < aliaslist.length; i++)
   world.note(aliaslist [i]);



PerlScript example

foreach $item (Win32::OLE::in ($world->GetAliasList))
 {
 $world->note($item);
 }



Python example

aliaslist = world.GetAliasList
if (aliaslist ):
  for a in aliaslist : world.Note (a)



Lua example

al = GetAliasList()
if al then
  for k, v in ipairs (al) do 
    Note (v) 
  end  -- for
end -- if we have any aliases



Lua notes

Lua returns nil where applicable instead of an "empty variant".



Return value

If there are no aliases (with names) then the return value is empty. Use "IsEmpty" to test for this possibility.

Otherwise, it returns a variant array containing the names of all the aliases. Use "ubound" to find the number of aliases in the list. You can then use "GetAlias" to find details about each alias.




See Also ...

Topics

DOC_aliases Aliases
DOC_mapper Auto-mapper
DOC_defaults Default triggers/aliases/timers/macros/colours
DOC_starting Getting started
DOC_group Groups
DOC_keypad Keypad navigation
DOC_macros Macro keys
DOC_plugins Plugins
DOC_regexp Regular Expressions
DOC_speed_walking Speed walking
DOC_timers Timers
DOC_triggers Triggers

Functions

FNC_AddAlias AddAlias (Adds an alias)
FNC_DeleteAlias DeleteAlias (Deletes an alias)
FNC_DeleteAliasGroup DeleteAliasGroup (Deletes a group of aliases)
FNC_DeleteTemporaryAliases DeleteTemporaryAliases (Deletes all temporary aliases)
FNC_EnableAlias EnableAlias (Enables or disables an alias)
FNC_EnableAliasGroup EnableAliasGroup (Enables/disables a group of aliases)
FNC_GetAlias GetAlias (Gets details about an alias)
FNC_GetAliasInfo GetAliasInfo (Gets details about an alias)
FNC_GetAliasOption GetAliasOption (Gets the value of a named alias option)
FNC_GetAliasWildcard GetAliasWildcard (Returns the contents of the specified wildcard for the named alias)
FNC_GetPluginAliasInfo GetPluginAliasInfo (Gets details about a named alias for a specified plugin)
FNC_GetPluginAliasList GetPluginAliasList (Gets the list of aliases in a specified plugin)
FNC_IsAlias IsAlias (Tests to see if an alias exists)
FNC_SetAliasOption SetAliasOption (Sets the value of a named alias option)

(Help topic: function=GetAliasList)

DOC_contents Documentation contents page