Hopefully "ScriptingTipsAndTricks" helps you with your batch file or vbscript scripting :-)
[Bottom][Contents][Prev]: Introduction[Next]: Current Directory (or Drive)
\->Introduction->Absolute & Relative File or Directory Names

Absolute & Relative File or Directory Names

There are two types of folders and files as follows:

  1. An absolute filename contains a drive (or UNC server name) as well as a path so that the location is fully qualified.

    For example with "C:\TMP\SomeFile.txt", you know that "SomeFile.txt" is in the "C:\TMP" folder.

  2. A relative filename on the other hand is missing drive or folder information and so its alsolute filename is dependant on the Current Directory or Drive.

    Without knowing the current directory/folder you can't tell where the file is, some examples:

There are some special folder names that have specific meanings in relative paths:

This Naming Files, Paths, and Namespaces page has some very useful file related information (including what the "\\?\" file prefix does (allow you to handle very long paths).


Microsoft awarded me an MVP (Most Valuable Professional award) in 2004, 2005, 2006, 2007, 2008 & 2009 for the Windows SDK (Windows Installer) area.Please email me any feedback, additional information or corrections.
See this page online (look for updates)

[Top][Contents][Prev]: Introduction[Next]: Current Directory (or Drive)


ScriptingTipsAndTricks© is (C)opyright Dennis Bareis 2003-2008 (All rights reserved).
Sunday September 07 2014 at 12:50pm
Visit ScriptingTipsAndTricks's Home Page
Microsoft awarded me an MVP (Most Valuable Professional award) in 2004, 2005, 2006, 2007, 2008 & 2009 for the Windows SDK (Windows Installer) area.