Hi ,
As far as I know, there is no build-in way could disable or hide "File name extensions" checkbox.
Since we can use Hid2FileExt (0 = Show,1 = Hide) registry key to check or uncheck the box of File name extensions.
As a work around, you can create a script that queries the data of the Hid2FileExt value, if it detect the value of Hid2FileExt is 1, it will auto set the registry value to 0. After enabling or disabling these registry values, the script then kills and restarts the Windows Explorer process.
The script may something around below ():
$hide = (Get-ItemProperty -path HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced).HideFileExt
If ($hide -eq 1) {
Set-ItemProperty -Path HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced -Name HideFileExt -Value "0"
}
For more question about PowerShell scripts , you can ask in our PowerShell forum.
Best Regards,
Candy
--------------------------------------------------------------
If the Answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.