Breaks a network connection.
wntCancelCon(local drive, persist, forceflag)
(s) local drive: the mapped device. Drive letter or UNC path.
(s) persist: @TRUE - update persistent connection table ;@FALSE - do not update persistent connection table to remove this device.
(i) forceflag: @TRUE to break the connection regardless of open files. @FALSE - if files are open, connection will not be broken.
(i) @TRUE if successful; @FALSE if unsuccessful.
You can use EITHER the drive letter OR UNC path name in the netcancelcon, wntcancelcon, w95cancelcon functions,in the 32-bit network extenders.
When a mapped local drive is specified, only that connection will be closed.
If persist is set to @TRUE, then the persistent connection will be updated to remove this drive mapping from the list of persistent connections.
NOTE: It is important to specify @TRUE for the persist parameter in wntCancelCon, if you plan to map this drive letter again using the function wntAddDrive.
If forceflag is set to @FALSE, wntCancelCon will not break the connection if any files on that connection are still open. If forceflag is set to @TRUE, the connection will be broken regardless.
; Load Appropriate Extender AddExtender('wwwnt34i.dll',0,'wwwnt64i.dll')
wntAddDrive(@DEFAULT,@DEFAULT,"\\SERVER\PUB\EXCEL","E:",@FALSE) RunWait("E:\EXCEL.EXE","\E") wntCancelCon("E:",@TRUE,@TRUE) Exit