create alias

Makes a new alias, symbolic link, or shortcut to the specified file or folder.

# Metadata

Platforms: desktop, server, mobile OS: mac, windows, linux, ios, android Introduced: 1.1 Security: disk

# Syntax

create alias aliasPath to {file | folder} originalPath

# Params

- aliasPath : The aliasPath specifies the name and location of the alias to be created. If you specify a name but not a location, the alias is created in the defaultFolder. - originalPath : The name and location of the file/folder you want to make an alias to. If you specify a name but not a location, LiveCode assumes the file is in the defaultFolder.

# Examples

create alias "Music Shortcut" to file "Music"

create alias preferredFileLocation to file "../Startup"

create alias "Photographs" to folder "Pictures"

# Description

Use the create alias command to create a second icon for a file or folder, in a location that is handier for the user.

You cannot create an alias to a disk volume.

To find out which file an alias refers to, use the aliasReference function.

>*Important:* When creating an alias on Windows, > make sure the alias name ends with the extension ".lnk" to > ensure that it behaves properly when the user double-clicks it.

# Tags

# See

- **keyword:** file - **property:** defaultFolder - **command:** revCopyFolder, create folder, revCopyFile, rename, revMoveFolder - **function:** aliasReference - **control structure:** function - **glossary:** symbolic link, shortcut, Windows, command, alias, extension