cottage Posted March 29, 2005 Posted March 29, 2005 Can someone please give me a little help with the following? RunWait(@Comspec & " /c " & 'net user $username urp@ss /add') How can I use a string (such as $username) with the above command? I've tried various ways of quoting it, but can't seem to find the right method. Regards, Bill
PerryRaptor Posted March 29, 2005 Posted March 29, 2005 Try this... RunWait(@Comspec & " /c " & "net user " & $username & " urp@ss /add") - $username cannot be inside quotes - note the spaces after "...user " and before " urp@ss..." Think of it as stringing all together "one" + "two" + 3 + "four"
cottage Posted March 29, 2005 Author Posted March 29, 2005 Try this...RunWait(@Comspec & " /c " & "net user " & $username & " urp@ss /add")- $username cannot be inside quotes- note the spaces after "...user " and before " urp@ss..."Think of it as stringing all together "one" + "two" + 3 + "four"<{POST_SNAPBACK}>Exactly what I needed. Thank you !!!
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