Click or drag to resize

Alias Function

X#
Return the alias of a specified work area as a string.

Namespace:  XSharp.RT
Assembly:  XSharp.RT (in XSharp.RT.dll) Version: 2.19
Syntax
 FUNCTION Alias(
	uWorkArea
) AS STRING CLIPPER
Request Example View Source

Parameters

uWorkArea (Optional)
Type: Usual
Any work area name or number.
If not specified, the alias of the current work area is returned.

Return Value

Type: String
If there is no database file in use, Alias() returns a NULL_STRING.
Remarks
Alias() is the inverse of Select(). Alias() returns the alias name given the work area number, while Select() returns the work area number given the alias name.
Examples
This example returns the name of the previously selected work area:
X#
1USE file1 NEW ALIAS Test1
2nOldArea := Select()
3USE file2 NEW ALIAS Test2
4QOut(Alias(nOldArea))            // Returns: Test1
See Also