Quick Links

Skip to main content Skip to navigation

Main Navigation

Top

Tech Blog

Sign up for the News Update.

Sub Navigation

Top

Headlines

 

Home > breadcrumbs: Products/Services > breadcrumbs: Tech Blog >

Working...

Ajax Loading Image

 

Network path in the command prompt

I spend a lot of time at the command prompt in Windows. I'm an old DOS guy, and frankly some things are easier at the command line than they are clicking and dragging things all over the place. While poking around the 'net, I came across a very helpful tip that will show you the UNC (\\server\directory) of the mapped network drive you are currently browsing. At the command prompt, type:

prompt $m$_$p$g

The $m echoes the Uniform Naming Convention (UNC) name of the drive letter that the command prompt currently displays;
the $_ inserts a carriage return and a line feed;
and $p$g are the standard drive and pathname with the greater-than symbol (>). This command caused the system to display the UNC name of network drives.

To make this change stick on a Win2K/XP system, you must modify/create an environment variable.

You do this by going to Control Panel, then System, then Advanced. From there, click the Environment Variables button, create a system variable named prompt, and set its value to $m$_$p$g. This will make the setting permanently display the remote network path every time you open a command prompt.

(info from: http://www.windowsitpro.com/article/articleid/16412/Command-Prompt-Tricks.html)

Network path in the command prompt

Date Subject Posted by:
No feedback has been posted yet. Please post yours!

Back To Top