Sign in to follow this  
Followers 0
scorpio82

net use drive mapping

5 posts in this topic

Hello,

my script:

#cs ----------------------------------------------------------------------------
AutoIt Version: 3.3.6.1
Author:      myName
Script Function:
Template AutoIt script.
#ce ----------------------------------------------------------------------------
; Script Start - Add your code below here
$cmd ="net use y: \\10.12.4.77\public\software\datamining\SAS_EGuide43_SoftDepot /persistent:yes"
RunWait(@ComSpec & " /c " & $cmd, "", @SW_HIDE)
$tekst = "1: E Guide" & @CRLF & "2: E guide E miner" & @CRLF & "4: E guide E miner E admin"
$keuze= InputBox("Software profiel kiezen",$tekst)
If $keuze = "1" Then
;keuze 1
$cmd = "Y:\INSTALL_Profile1_EGUIDE.CMD"
RunWait(@ComSpec & " /c " & $cmd, "y:\"); , @SW_HIDE)



EndIf
#cs If $keuze = "2" Then
;keuze 2
$cmd = "y:\INSTALL_Profile2_EGUIDE_EMINER.CMD"
RunWait(@ComSpec & " /c " & $cmd, "y:\"); , @SW_HIDE)




EndIf
If $keuze = "4" Then
;keuze 4
$cmd = "y:\INSTALL_Profile4_EGUIDE_EMINER_ADMIN.CMD"
RunWait(@ComSpec & " /c " & $cmd, "y:\"); , @SW_HIDE)




EndIf
#ce

My question:

How do I delete the Y:

Do I put above $cmd=... "net use y: \\ del"

Can someone help me

Kind regards,

Steven

Share this post


Link to post
Share on other sites



$cmd = "net use Y: /delete"

Share this post


Link to post
Share on other sites

Another option, in case you don't want to use the Net Use command

DriveMapDel("Y:")

If you try to fail and succeed which have you done?AutoIt Forum Search

Share this post


Link to post
Share on other sites

Thanks a lot!

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0