Support Forum: Get Support for Patch My PC Products and Services

Microsoft Configuration Manager and Intune (Enterprises/Paid) => Support and General Questions (Enterprises Using ConfigMgr and Intune) => Topic started by: GeoSimos on March 08, 2022, 09:53:22 AM

Title: Interactive user notifications question regarding the Application ID
Post by: GeoSimos on March 08, 2022, 09:53:22 AM
Hello,

I'm in the process of replacing multiple versions of KeePass (1.x and 2.x, MSI and EXE Setups) with the latest one that is based on MSI installer.
However, I don't have all the previous versions covered by PatchMyPC due to quite old installations, manual ones and the application retention I have set in the publisher.
Because I have either on hand or have located and downloaded all the installers needed, I have created respective applications to be superseded by the latest one but also provide the uninstall command to remove the old ones.
I wanted to use the ability of the "Interactive user notifications" feature in PatchMyPC and use the binaries and modified Package.XML and Detection Scripts as the base of these applications (something that I have done a couple of times succesfuly so far and it is really cool).
However, setting the notification settings and republishing the content for the latest application's version, I noticed in Package.XML the following (sample application based on the Setup.exe installer):
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<Package>
  <VendorName>Dominik Reichl</VendorName>
  <ProductName>KeePass v1 - EXE Install</ProductName>
  <AppNameFilter>KeePass Password Safe%</AppNameFilter>
  <AppVersionFilter>1.40</AppVersionFilter>
  <SilentUninstallArg>/verysilent</SilentUninstallArg>
  <CommandLine>/MainFile=KeePass-1.40-Setup.exeÿ"/MainArg=/VERYSILENT /NOCLOSEAPPLICATIONS /NORESTARTAPPLICATIONS /NORESTART /SP- /SUPPRESSMSGBOXES"ÿ/BlockingProcessPolicy=Notifyÿ/UserNotificationTimeout=120ÿ/PreventConflictingProcessRestartÿ/NotificationPolicy=AutoCloseÿ/FocusAssistPolicy=DiscardNotificationÿ"/ApplicationName=KeePass v1 - EXE Install"ÿ/[b]ApplicationID=2e630e69-0b39-4b2b-a6c0-3cc3bf8b551b[/b]ÿ/KillProcessList=KeePass.exeÿ/ShortcutFileName=KeePassÿ/LoggingSwitch=/LOG={path}ÿ/PrefixInstallLogÿ/LoggingPath=C:\windows\ccm\logs\PatchMyPCInstallLogsÿ/LogRetentionDays=28</CommandLine>
  <InstallationBehavior>System</InstallationBehavior>
  <PackageID>TST123AB</PackageID>
</Package>

So the ApplicationID is something I haven't noticed before (as it isn't present if you don't use the user notifications feature), I wanted to ask the following:
1) Is this GUID generated arbitrary or not
2) If not, is it related to any files accompanying the applications such as the .exe, .msi, .dll ones?
3) Last but not least, if it isn't related, can I create one by myself to add it in the applications created by me, in order to leverage your solution's functionality?

Thank you.
Title: Re: Interactive user notifications question regarding the Application ID
Post by: Jake Shackelford (Patch My PC) on March 08, 2022, 10:26:01 AM
It's an ID generated by ConfigMgr
Update ID if it's an update and deployment type ID for applications

It's used to track things in the registry like deferrals or max run time and a slew of other things

It is technically the ModelName from the SMS_DeploymentType object

At the end of the day ConfigMgr controls it.
Title: Re: Interactive user notifications question regarding the Application ID
Post by: GeoSimos on March 08, 2022, 11:30:17 AM
Hi Jake,

Thank you for the quick response, I will check the Deployment Type ID if it matches and will revert if needed.
Title: Re: Interactive user notifications question regarding the Application ID
Post by: Jake Shackelford (Patch My PC) on March 08, 2022, 01:40:43 PM
You would need to query the SMS_DeploymentType Object and grab the Model name which should give you what you need. How you query that is up to you.
Title: Re: Interactive user notifications question regarding the Application ID
Post by: GeoSimos on March 08, 2022, 01:42:50 PM
Very nice, thank you!
Title: Re: Interactive user notifications question regarding the Application ID
Post by: GeoSimos on March 09, 2022, 03:49:58 AM
Coming back for this, the best way to get the Model Name for a deployment type (for one or multiple applications) is by using the SCCM powershell cmdlets.
Example:
Get-CMDeploymentType -ApplicationName "KeePass*" | Select-Object -Property LocalizedDisplayName, CI_UniqueID, ModelName | Out-Gridview
You can omit the CI_UniqueID but it is a good thing to have and compare with ModelName.

Thank you again Jake!