VBS Script to get the location of the current script

Here is just a quick example of how to get the location of the currently running script.

currentScriptPath = Replace(WScript.ScriptFullName, WScript.ScriptName, "")

strLogFile = currentScriptPath & "log.txt"

wscript.echo strLogFile


Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.