Here is the action script which works with WINXP and WIN2003. In windows 7 this doesn’t work.
Does anybody know how I can delete the desktop icon with a variable in WIN7?
//Delete Desktop icon
delete “{pathname of files whose (name of it equals “Adobe Reader 9.lnk”) of folder (value of variable “allusersprofile” of environment & “\Desktop”)}”
In Windows 7 Desktop icons are stored in a different location. The all users desktop is no longer in the “allusersprofile” folder but instead it is located in the C:\Users\public\Desktop folder. I believe if you use the script below it will work, I modified your variable to “public” instead of “allusersprofile”
//Delete Desktop icon
delete “{pathname of files whose (name of it equals “Adobe Reader 9.lnk”) of folder (value of variable “public” of environment & “\Desktop”)}”