Quantcast
Channel: The Official Scripting Guys Forum! forum
Viewing all articles
Browse latest Browse all 15028

PowerShell Script to do a Specific Function

$
0
0

Hello All, I am a complete noob to PowerShell Scripting and am anxious to learn more.

I need to create a PS script to perform the following functions in a single script and have no idea how. I have listed the required functions below, any help would be great.

# Log into "ServerName" as Administrator
# Open a command prompt:
# Run DOS Command - net user "username" /add /random
# Log off Server
# Log into "AnotherServerName" as Administrator
# Open a Command Prompt:
# Run DOS Command - net user "username" /add /random
# Then go to "c:\FolderName\FolderName" and add the "UserName" to "TextFileHere.txt" text file and Save it.
# Then in the same directory, Run the "AGreatVBSScript.vbs" script

Thanx


Viewing all articles
Browse latest Browse all 15028

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>