Skip to main content

CM Icons for Applications, Packages, and Task Sequences

An important, but often neglected, feature of Software Center is to associate icons with the visible deployments in Software Center.  You can add a visible icon to your Available things in Software Center:  Applications, Packages(Advertisements), and Task Sequences (Advertisements... or OSD deployments).

A few 'things to know'

  • Icons can be added to Applications, Packages (for Advertisements) and Task Sequences (for OSD or more complex deployments)
  • "In general", icons in 512x512 format look the best.  pictures or icons GREATER than 512x512 may not be able to be selected.  That doesn't mean you can't use 256x256, or really, any .png as long as it is smaller than 512x512.
  • "The file" known as "usethisPicture.png" doesn't get imported when you select it.  What gets imported is a string which "represents" that image.

Where to 'get' icons to use.

  • The already-installed application itself.  For example, you can go to \\SomeWorkstation\c$\Program Files\TheApp\TheApp.exe, and there will usually be an icon that the vendor themselves decided represents that application.
  • There are multiple 'icon repositories' out there, for example, iconarchive.com.  Perhaps you are looking for "the perfect" AutoCAD icon.  Search for AutoCad, and you will be presented with multiple (for free!) options.  Select the one you like, download it.  Now that you have the .png file, save it in a known location to use later.
  • Image manipulation + online .ico converter.  If there simply isn't ANYTHING you can find that you like at all, pre-created, you can screen shot something, edit it in a image editor, and/or web browse for something like "free icon converter", which will usually take an input file, and output a .png or .ico for you.
  • "for fun" in %windir%\system32 is a file called 'moricons.dll' (yes, there is no e in that).  It's a hold over from... wait for it... Windows 3.1!  Select that file for some old skool nostagia.

How to associate icons with a..
Application

  • Console, Software Library, Application Management, Applications
  • Find the application, right-click and select 'Properties'
  • Software Center tab, and near the bottom by "icon", Browse...
  • Browse to where you identified the icon to use (program files on a workstation, a downloaded .png or .ico file...)
  • Once selected, in the console you will see a representation of the icon, OK.

Package

  • Console, Software Library, Application Management, Packages
  • Find the Package, right-click and select 'Properties'
  • Near the bottom by "icon", Browse...
  • Browse to where you identified the icon to use (program files on a workstation, a downloaded .png or .ico file...)
  • Once selected, in the console you will see a representation of the icon, OK.

Task Sequence

  • Console, Software Library, Operating Systems, Task Sequences.
  • Find the Task Sequence, right-click and select 'Properties'
  • on the 'More Options' tab, near the bottom by "icon", Browse...
  • Browse to where you identified the icon to use (program files on a workstation, a downloaded .png or .ico file...)
  • Once selected, in the console you will see a representation of the icon, OK.

How to know what Apps, Packages, or Task sequences are missing an icon

So, that's all great that you can... but how do you know which ones are missing an icon, and/or what the icon looks like, without deploying 'everything' to yourself?  Why, use a report of course!

Although it's not perfect (the sql doesn't filter by deployed AND visible in SC, just 'deployed', so if it is required and hidden from the user in SC, it will still show up on this report, even if you select @deployed=1), but if you want to see if something is 'missing an icon', if the Iconb column is blank... there is no icon defined.

--DECLARE @Deployed int = 1

IF @Deployed = 1
BEGIN
;WITH XMLNAMESPACES ( DEFAULT 'http://schemas.microsoft.com/SystemsCenterConfigurationManager/2009/06/14/Rules', 'http://schemas.microsoft.com/SystemCenterConfigurationManager/2009/AppMgmtDigest' as p1)
select 
cci.SDMPackageDigest.value('(/p1:AppMgmtDigest/p1:Application/p1:DisplayInfo/p1:Info/p1:Title)[1]', 'nvarchar(max)') AS [Name]
,cci.SDMPackageDigest.value('(/p1:AppMgmtDigest/p1:Resources/p1:Icon/p1:Data)[1]', 'nvarchar(max)') AS [Iconb],
Type='Application'
,cci.CI_UniqueID as 'Identifier'
from vCI_ConfigurationItems cci 
join v_CIAssignment cia on LEFT(cia.AssignmentName, CHARINDEX('_', cia.AssignmentName + '_') - 1)=cci.SDMPackageDigest.value('(/p1:AppMgmtDigest/p1:Application/p1:DisplayInfo/p1:Info/p1:Title)[1]', 'nvarchar(max)')
where citype_id=10
and cci.IsLatest=1
UNION ALL
select SMSPackages.Name, 
Cast('' AS XML).value('xs:base64Binary(sql:column("SMSPackages.icon"))','varchar(MAX)')
,case when SMSpackages.Packagetype=0 then 'Package'
when SMSPackages.Packagetype=4 then 'Task Sequence'
else cast(SMSPackages.PackageType as varchar) end as 'Type'
,SMSPackages.PkgID as 'Identifier'
from SMSPackages
join v_DeploymentSummary ds on ds.PackageID=SMSPackages.PkgID
where smspackages.packagetype in (0,4)
END
If @Deployed = 0
BEGIN
;WITH XMLNAMESPACES ( DEFAULT 'http://schemas.microsoft.com/SystemsCenterConfigurationManager/2009/06/14/Rules', 'http://schemas.microsoft.com/SystemCenterConfigurationManager/2009/AppMgmtDigest' as p1)
select 
cci.SDMPackageDigest.value('(/p1:AppMgmtDigest/p1:Application/p1:DisplayInfo/p1:Info/p1:Title)[1]', 'nvarchar(max)') AS [Name]
,cci.SDMPackageDigest.value('(/p1:AppMgmtDigest/p1:Resources/p1:Icon/p1:Data)[1]', 'nvarchar(max)') AS [Iconb],
Type='Application'
,cci.CI_UniqueID as 'Identifier'
from vCI_ConfigurationItems cci 
where citype_id=10
and cci.IsLatest=1
UNION ALL
select SMSPackages.Name, 
Cast('' AS XML).value('xs:base64Binary(sql:column("SMSPackages.icon"))','varchar(MAX)')
,case when SMSpackages.Packagetype=0 then 'Package'
when SMSPackages.Packagetype=4 then 'Task Sequence'
else cast(SMSPackages.PackageType as varchar) end as 'Type'
,SMSPackages.PkgID as 'Identifier'
from SMSPackages
where smspackages.packagetype in (0,4)
END

Now, let's say you've created a report in Report Builder, and added all the columns... but that iconb column..where everything starts with iVBORw... means nothing to your human eye.

How to make that look like a icon in Report Builder: Add a column, and for that square in the table, right-click, Insert, Image, Select "Database" as the image source. Now, select 'Iconb' for 'Use this field', and for the MIME Type, select image/png.

 

IconsReport

ConfigMgr

  • Created on .