Dryden Posted November 9, 2007 Share Posted November 9, 2007 Hi! I need some help, do any of u guys know a way of a script detecting where it's being runed from? For example. I wanted a script that I could copy to any place and it outputs 2 things: The full path where it is located and the drive lerrer (c:\d:\e:\etc.). So if I put my scprit in c:\windows\myscript.exe, whe I run it it should output 2 variables whith the folowing values: $var1="c:" "$var2="\windows\" I dunno if I'm making sense, but i think I am. :S Any Ideas on how to do this? thx in advance. "Build a man a fire, and he'll be warm for a day. Set a man on fire, and he'll be warm for the rest of his life." - Terry Pratchett. Link to comment Share on other sites More sharing options...
Valuater Posted November 9, 2007 Share Posted November 9, 2007 @ScriptFullPath then use _PathSplit() 8) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now