Recently I read a post from XD Tipster on how to convert Png files into icons and use them for XenDesktop and Storefront… A very interesting piece, but a bit convoluted and long winded for my liking. I didn’t like the idea of the two website hops to get this information into XenDesktop format… So I decided to write two utilities:
Iconizer Converts png files (with transparency supported) to an Ico file format , then in turn converts it To a Base 64 String.
You can send the data to the clipboard or import directly into XenDesktop if you have the powershell tools available.
It’s very simple, I wont bore you with the details, just convert and import. then map with powershell:
I’m sure you can guess, takes the massive string of information stored in base64 and gives you a visual representation.
An example command line of how to do this is below:
Why didn’t you integrate both of these?
Well it seems .net and Powershell have a limit on the data (string length) it can pull out of the pipeline. The default Citrix icon is close to 20,000 characters and results in you being unable to pull this data from powershell directly to .net. WIth great help from http://www.jonathanmedd.net/ we found that, yep the console does seem to have a roughly 8k char limit… Sure I could parse it to a file or the clipboard, but that was messy and frankly, I really couldn’t be arsed.
If you are up to the challenge I’ve got the source code for forward and reverse of the icon data below. I’ve also got a half assed attempt at creating a list… So fill your boots and take up the challenge if you wish.
As with most of my utilities the download links and source code are below, and a few icons to get you going: