This post has already been read 7707 times!
Its been a while, but its good to be back and have something to write about.
The title of this post pretty much says it all. I was having a really troublesome time getting Citrix Workspace App working seamlessly in my environment here. First we will start with the scenario
Published Desktop to act as a “skin” for the apps.
Skype for Business will be on the VDA that runs the published desktop so that it can be launched at login and be used to “Share Screen”. The reason for this is the rest of the applications are in separate silos due to app compatibility and hosting Skype for business on the Published Desktop VDA allows ALL apps to be visible via the screen share.
Citrix Workspace App will be on the Published Desktop VDA and will SSO on behalf of the user, this will then add all the available published applications to the users Start Menu.
The user should have the ability to pin these icons to the Taskbar or to the desktop and these should persist between sessions.
With the above in mind I set up a new VDA (2012 R2 in this case – I know, I know), installed Workspace App, Configured SSO, set up Skype for Business and the HDX optimisation pack and configured the relevant Group Policies to lock the desktop down.
Duplicate Start Menu Icons
Once Logged in for the first time all looked great. I could see the shortcuts in the Start Menu and also in Workspace App. However, after logging out and back in I noticed that the Start Menu icons were being duplicated.
If you look at the file location on the disk where this shortcut is you will see that there are duplicates being created at each login but only one is appearing in the Start Menu
After a bit of googling I came across this article by Citrix
This talks about adding a registry value in the Dazzle key called “SelfServiceFlags”
Once this was put in and I cleared out my existing profile I logged in and out a few times and hey presto – nice clean start menu!
Great, so now my users are logging into the published desktop, getting full SSO and all their apps in their start menu. Next Problem was pinned icons.
As you can see I have pinned Putty and Visual Studio to the task bar and Remote Desktop Manager to the Desktop.
Now I again logged out and back in and saw the following.
As you can see the shortcuts have persisted across sessions but the icons have vanished. This was not ideal as it did not look too good and also the users would have to hover over the icon to find out what it was.
I started to look into it and checked the properties of the shortcut.
Looking at the target for this and you will see this:
“C:\Program Files (x86)\Citrix\ICA Client\SelfServicePlugin\SelfService.exe” -launch -reg “Software\Microsoft\Windows\CurrentVersion\Uninstall\bretty-eedc30b8@@xd.Visual Studio 2017” -startmenuShortcut
If you look at the section on bold you will see that it is referring to a location in the Current User registry. Next I checked that. As you can see from the image below there is a value in there called DisplayIcon
If we have a look at what is in there you will see the full path to the icon file
Lets go and have a look at those files and see if the one for my pinned shortcut is missing?
As you can see, there is an icon for Visual Studio there but it has a random string of numbers at the end. Looks like a time stamp right? YEAR/MONTH/DAY etc – you get the idea. It is. Turns out that every time I log into the server Workspace App regenerated these icons with the unique timestamp.
Whilst this is great for a clean start menu, it is not great for pinned icons as the one you pinned in your last session is referring to the icon that was generated in your last session and not the one you have generated for this session. Hence the white box. You can check this by clicking the “Change Icon” button of the shortcut.
As you can see it cant find the icon, that’s because it was regenerated at login with a different timestamp.
Easy to fix – just add the SelfService\Icons path to the folders to sync. This does work, BUT, as every icon changes at every login your profile bloats a lot and fast.
What we need is something to do this:
- At logoff check both Pinned and Desktop Shortcuts
- If they are a Self Service Shortcut then process them
- Check for a valid icon file
- check if that exists on the network share
- If not then copy it up
- At Logon sync your backed up icons to the Self Service directory
With that in mind I broke out Visual Studio and wrote CitrixWorkspaceIconSync. It is a console app to do exactly the above.
The source code is up on GitHub so feel free to edit / hack / comment on it as much as you like but please go easy – I’m a complete n00b to “proper” programming. If you want the exe file then download it here or feel free to download it from GitHub and compile it yourself.
Thanks about it from me, hope this helps some of you out.