#Changing Standard App via Powershell

7 messages · Page 1 of 1 (latest)

grand sable
#

Hi! Is it possible to change the standard app via Powershell? In my case its pdf, but I feel like everything I try doesn't work out. >_>

Specifically got the task at work and figured it would be super easy, as setting it manually takes like 5 seconds.

Tried to edit the Registry (No Permission) Dism (No Permission)..

Any hint would be appreciated. :(

Read about SetUserFTA, but very unlikely I am allowed to use 3rd Party Software.
Just feels like I am missing something since manually changing the setting is so easy.

amber nebula
#

There is no official API from Microsoft aside from asking the user their choice interactively. The SetUserFTA is a 3rd party implementation that reversed engineered the hashing mechanism in the registry that stores the valur

grand sable
#

Oh I see :( I guess I could let a script open the settings to change it manually but thats kinda scuffed 😭

rich forum
#

user logon script in GPO that uses that and then does some simple logic to set pdf viewer based on what they have installed


# Check for Nuance PDF
if (Test-Path 'HKLM:\SOFTWARE\ScanSoft\PDF Converter 8.0') {
  Set-FTA 'GaaihoDoc.Document' .pdf
}
# Check for Acrobat 2020
elseif (Test-Path 'HKLM:\SOFTWARE\Adobe\Adobe Acrobat\2020') {
  Set-FTA 'Acrobat.Document.2020' .pdf
}
# Adobe Reader
else {
  Set-FTA 'AcroExch.Document.2020' .pdf
}
grand sable
#

I will look into that, thank you already!!

rich forum
#

yw 🙂