LoginSignup
2
1

More than 1 year has passed since last update.

相対パスでショートカットを作る

Posted at

問題

USBメモリの中には、ツールやアプリなどを早く起動するためにショートカットを作成しました。
しかし、異なるPCではドライバの名前が異なるため、ショートカットが正常に動作しないことがよくあります。
相対パスを使用することで、この問題を解決できます。

やり方

「Snipaste.exe」を例として、説明します。
image.png

  1. ショートカットを作成し、置きたい場所に移動する
    「Tools」フォルダの下に置いた
    image.png
  2. 下図の赤枠を修正する
    image.png
    ① 相対パスに変更する
    相対パスの前%windir%\explorer.exe を追加する
    %windir%\explorer.exe "\Snipaste-2.8.3-Beta-x64\Snipaste.exe"
    ② 空白にする
    image.png
  3. 適用ボタンとOKボタンを押す
    image.png

できました。
「Tools」フォルダのパスを変更しても、ショートカットを起動できます。

2
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
1