Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

This question already has an answer here:

Is there a way to create a shortcut to an EXE on a USB thumb drive that will work no matter what drive letter is assigned to the thumb drive?

I have a program in a folder on a thumb drive. I want to create a shortcut in the root of the thumb drive that points to the program's EXE and will work no matter what drive letter is assigned to the thumb drive.

How can I do this?

share|improve this question

marked as duplicate by Karan, mdpc, smc, Kevin Panko, Ramhound May 17 at 5:35

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

2 Answers 2

up vote 8 down vote accepted

You should be able to leave off the drive letter to create a relative pathname. For example, if your executable is at:


set the shortcut to be:


or perhaps:


A bit of experimentation should reveal the correct format.

share|improve this answer
Relative is the way to go, +1. –  John T Feb 24 '10 at 23:25
I just came across this. Windows has never supported creating shortcuts with relative paths AFAIK (if you leave out the drive letter it will still be added), so I don't know why this is the accepted answer. –  Karan May 14 at 20:03

We can also use batch files to achieve relative links.
Just put,

start path/to/program.exe

and put it in the root of the flash drive..
I am not sure if relative shortcuts(lnk files) can be used in windows...

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.