Hi. I have had a look at the scripts on Spiceworks. One of the scripts that I want to try out, shows the code and is used with Powershell.<\/p>\n
So I open ‘powershell’ and then copy paste the text into it to run? Is that it? I tried that but red lines of error came up. Am I doing something wrong? Sorry new to scripting, I know basics like renaming a notepad file with crediable code in it as ‘.bat’ what about vbscript files how can I run them? thanks<\/p>","upvoteCount":2,"answerCount":3,"datePublished":"2011-09-27T07:00:01.000Z","author":{"@type":"Person","name":"lazo111","url":"https://community.spiceworks.com/u/lazo111"},"acceptedAnswer":{"@type":"Answer","text":"
You can run the scripts from within a powershell ISE (powershell 2.0). For automation you would usually use the commandline. Something like:<\/p>\n
powershell ./script.ps1<\/p>\n
You need to specify the exact path or ./ for current directory.<\/p>\n
Another issue is that the machine that the script is run on will often need to have permission to run the script.<\/p>\n