/build/static/layout/Breadcrumb_cap_w.png

Hi i need a vb script to delete a file inside the alluser profile

I need to delete a shourtcut inside the alluser profile
Path= %ALLUSERPROFILE% \start menu\aaa\xxx\zzz.url

Can any one give the script for me?.

Thanks in advance


[/align][/align][/align]

0 Comments   [ + ] Show comments

Answers (1)

Posted by: Poochie 13 years ago
Senior Yellow Belt
0
Would look something like that:

Dim Path

set objShell = createobject("Wscript.Shell")
Set FSO = CreateObject("Scripting.FileSystemObject")
Path = objShell.SpecialFolders("AllUsersPrograms") & "\MODIFY_PATH_HERE\FILE.XYZ"
MsgBox "Allusers Programs: " & Path
Set FileToDelete = FSO.GetFile(Path)
FileToDelete.Delete
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ