JScript getScriptPath

Author Johnny Josefsson on February 19, 2010 | Print | Bookmark
function getScriptPath()
{
 var strScriptPath = WScript.ScriptFullName;
 var strScriptName = WScript.ScriptName;
 var strGetScriptPath = strScriptPath.replace(strScriptName, "");

 return strGetScriptPath;
}

Was this article helpful?

Yes No

Category: Scripting, JScript

Last updated on May 15, 2011 with 1631 views