Permission Denied When Delete folder
Hi guys,
I create a folder name "Test" in E driver and create a Jscript in it. Below are the script code:
Shell = new ActiveXObject('WScript.Shell');
fso = new ActiveXObject('Scripting.FileSystemObject');
fso.DeleteFile(WScript.ScriptName)
fso.DeleteFolder('E:\\Test',true);
Shell.Popup('Uninstall Success.', 0, 'Info', 0 | 64);
An "Permission Denied" error occur when I run above script because when the script try to delete the folder, the folder is in used by the script itself. Please help ,thx.