• Welcome to Theos PowerBasic Museum 2017.

IWshNetwork.RemoveNetworkDrive Method

Started by José Roca, July 14, 2008, 08:18:37 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

José Roca



The following code removes the logical drive "E."

JScript

var WshNetwork = WScript.CreateObject("WScript.Network");
WshNetwork.RemoveNetworkDrive ("E:");


VBScript

Dim WshNetwork
Set WshNetwork = WScript.CreateObject("WScript.Network")
WshNetwork. RemoveNetworkDrive "E:"


PowerBASIC

DIM pWshNet AS IWshNetwork
pWshNet = NEWCOM "WScript.Network"
pWshNet.RemoveNetworkDrive UCODE$("E:")