Harshmage Posted September 1, 2009 Share Posted September 1, 2009 Okay, I'm just a bit new to this but I do have a question or two. I've got an AutoIt script that asks for a username, password, and password confirmation, and creates a user account with those creds on the local machine. Great, works nice. Not an issue. But what I'd like is to also create a script that maps the network drive for that user. Registry key, batch file... User accounts are mapped to the SAN like this: \\server.edu\home\<U>\<S>\<USERNAME>\ Even if I have to create a separate script to ask for username/password on their own login, automation is what I'm after. As these machines aren't going to be part of AD, they're going to not have anything related to standard roaming profile scripts. Login scripting with AutoIt to ask for username/password to map the network drive as they're logging in? Exit out if the User Create account is the one logged in? Sorry, I'm brainstorming, and posting so I don't forget. Link to comment Share on other sites More sharing options...
99ojo Posted September 1, 2009 Share Posted September 1, 2009 Okay, I'm just a bit new to this but I do have a question or two. I've got an AutoIt script that asks for a username, password, and password confirmation, and creates a user account with those creds on the local machine. Great, works nice. Not an issue. But what I'd like is to also create a script that maps the network drive for that user. Registry key, batch file... User accounts are mapped to the SAN like this: \\server.edu\home\<U>\<S>\<USERNAME>\ Even if I have to create a separate script to ask for username/password on their own login, automation is what I'm after. As these machines aren't going to be part of AD, they're going to not have anything related to standard roaming profile scripts. Login scripting with AutoIt to ask for username/password to map the network drive as they're logging in? Exit out if the User Create account is the one logged in? Sorry, I'm brainstorming, and posting so I don't forget. Hi, see helpfile DriveMapAdd and IsAdmin. I would do it like this: Put the exe in All User Profile Autostart and exit script if user is admin. ;-)) Stefan Link to comment Share on other sites More sharing options...
Dschingis Posted September 1, 2009 Share Posted September 1, 2009 (edited) If everything fails you can use the good old command line tools runaswait("user","domain","Password",1,@ComSpec & " /c net use x: \\server.edu\home\<U>\<S>\<USERNAME>\") This should work on every windows computer w/o problems. I suggest to encrypt / decrypt the credentials if using account informations within a script. Hope that helps. D. Edited September 1, 2009 by Dschingis 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