en-UShe-IL
You are here:   Blog
Register   |  Login

Blog Archive:

Maximize
* Can be used in order to search for older blogs Entries

Search in blogs


Blog Categories:

Maximize
* Can be used in order to search for blogs Entries by Categories

Blog Tags:

Maximize
* Can be used in order to search for blogs by keywords

TNWikiSummit


Awared MVP 


 


Microsoft® Community Contributor 


Microsoft® Community Contributor


Read first, before you you use the blog

Maximize
מאי11

Written by: ronen ariely
11/05/2018 16:33 RssIcon

Do you want to have a shortcut links in your portable device which point to a files in the portable device?

Let’s say that you use an external device like disk-on-key or external backup disk, and you have some applications on that disk stored in sub folders. We want to create shortcuts to the executable files of the applications.

For example I am using Sql Server Operations Studio, which is Microsoft new tool to manage SQL Server. This app does not require any installation and you can store it in your disk-on-key. At this time my external disk has the drive letter E and the path to my executable file is: “E:\sqlops-windows-0.27.3\sqlops.exe”.

The problem is that if I will create a link to this path, it might not work the next time I am using the same disk, since the drive letter is given dynamically when we plugin the device (it might be Z next time instead of E). Unfortunately, windows does not have built in option to create a relative path like “.\sqlops-windows-0.27.3\sqlops.exe”, but the solution is simple.

The solution is actually very simple using small trick. Instead of creating a direct link to the file, we can create link to the “explorer.exe” application which we all have in our windows systems. This small tool can get input of relative path to a file we want to explore(execute). We can use a system PATH variable like “%windir%” to point to the explorer app, and using the explorer we will execute our application using relative path.

Using this small trick instead of using the direct link “E:\sqlops-windows-0.27.3\sqlops.exe” I can create shortcut like this: %windir%\explorer.exe ".\sqlops-windows-0.27.3\sqlops.exe"

This is how I am using portable application on my external disk, ready to be execute during me next lecture from any device I will store my session’s materials :-)

Tags: shortcut , windows
Categories: Other...
Location: Blogs Parent Separator Public blog