Solved

Windows 7 Group Policy created icons disappearing

Posted on 2012-12-28
3
917 Views
Last Modified: 2013-01-15
I have a logon VB script that creates desktop icons on our users pc's for some commonly used links.  For whatever reason sometimes when they log on some of the icons are not there.  They log off and back on and they appear.  This seems to be only related to windows 7 machines.  Do you know of any issues with 7 that would cause this or is there something wrong with my script.  Here is a copy of my script.  THank you


'FORCE EXPLICIT VARIABLE DECLARATION
option explicit

'STEP OVER ERRORS FOR CUSTOM ERROR REPORTING
on error resume next

'DECLARE VARIABLES
dim shell, desktopPath, link, sys32Path

'INSTANTIATE THE WINDOWS SCRIPT HOST SHELL OBJECT
Set shell = WScript.CreateObject("WScript.shell")

'SET THE PATH TO THE WINDOWS DESKTOP FOLDER & MY DOCUMENTS FOLDER
desktopPath = shell.SpecialFolders("Desktop")
sys32Path = "http://home"

'CREATE A SHORTCUT ON THE USER'S DESKTOP
Set link = shell.CreateShortcut(desktopPath & "\TriCounty Citrix.lnk")

'SET THE PROPERTIES FOR THE SHORTCUT
link.Description = "My Shortcut"
link.TargetPath = sys32Path
link.WindowStyle = 0
link.WorkingDirectory = desktopPath
link.IconLocation = "\\tch16\IT\ShortcutIcons\epic.ico"
link.Save

'CLEANUP OBJECTS
set shell = nothing
0
Comment
Question by:TriCountyIT
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 10

Accepted Solution

by:
George Khairallah earned 500 total points
ID: 38727947
To directly answer your question, I'm not sure why the icons are disappearing. However, I do have a suggestion on doing this more efficiently.
Have you looked at the Shortcuts GPO preferences?  
I actually wrote a blog article not too long ago about this very task, you can check it out here:
http://blog.foreignkid.net/2012/10/working-preference-gpos/
0
 
LVL 7

Expert Comment

by:John Jennings
ID: 38779490
In reality, I'd recommend using the group policy to:

a) Create a new GPO that is filtered and effectively only for Windows 7 machines.
b) Setup Shortcuts preferences inside this new GPO.

The scripts will still function for your older workstations, however, with the new capabilities of Group Policy you're going to want to use the new stuff. Easier to manage and grow.
0
 

Author Closing Comment

by:TriCountyIT
ID: 38779959
I didnt know about this!! Thank you this is going to make my life a lot easier!!
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Possible fixes for Windows 7 and Windows Server 2008 updating problem. Solutions mentioned are from Microsoft themselves. I started a case with them from our Microsoft Silver Partner option to open a case and get direct support from Microsoft. If s…
There are many software programs on offer that will claim to magically speed up your computer. The best advice I can give you is to avoid them like the plague, because they will often cause far more problems than they solve. Try some of these "do it…
This Micro Tutorial will give you a basic overview of Windows DVD Burner through its features and interface. This will be demonstrated using Windows 7 operating system.
The Task Scheduler is a powerful tool that is built into Windows. It allows you to schedule tasks (actions) on a recurring basis, such as hourly, daily, weekly, monthly, at log on, at startup, on idle, etc. This video Micro Tutorial is a brief intro…
Suggested Courses

622 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question