Movatterモバイル変換


[0]ホーム

URL:


Skip to main content

This browser is no longer supported.

Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.

Download Microsoft EdgeMore info about Internet Explorer and Microsoft Edge
Table of contentsExit editor mode

mklink

Feedback

In this article

Creates a directory or file symbolic or hard link.

Syntax

mklink [[/d] | [/h] | [/j]] <link> <target>

Parameters

ParameterDescription
/dCreates a directory symbolic link. By default, this command creates a file symbolic link.
/hCreates a hard link instead of a symbolic link.
/jCreates a Directory Junction.
<link>Specifies the name of the symbolic link being created.
<target>Specifies the path (relative or absolute) that the new symbolic link refers to.
/?Displays help at the command prompt.

Examples

To create and remove a symbolic link named MyFolder from the root directory to the \Users\User1\Documents directory, and a hard link named Myfile.file to the example.file file located within the directory, type:

mklink /d \MyFolder \Users\User1\Documentsmklink /h \MyFile.file \User1\Documents\example.filerd \MyFolderdel \MyFile.file

Related links


Feedback

Was this page helpful?

YesNoNo

Need help with this topic?

Want to try using Ask Learn to clarify or guide you through this topic?

Suggest a fix?

  • Last updated on

In this article

Was this page helpful?

YesNo
NoNeed help with this topic?

Want to try using Ask Learn to clarify or guide you through this topic?

Suggest a fix?