Recently I asked to install fonts in 3000 Windows 10 1809 devices. So normally I have 2-3 scripts to install fonts like batchfile, VBS and customized with MSI file.
Surprisingly all methods failed to install fonts in Windows 10 1809 version.
Tried on search engines and getting many posts related to this people are having issue with installing fonts on Windows 10 1809.
Finally I have used below script for Install fonts on Windows 10 1809-
I have created Font.ps1 and follow the normal Package and distributed. Now its working great for me.
Surprisingly all methods failed to install fonts in Windows 10 1809 version.
Tried on search engines and getting many posts related to this people are having issue with installing fonts on Windows 10 1809.
Finally I have used below script for Install fonts on Windows 10 1809-
I have created Font.ps1 and follow the normal Package and distributed. Now its working great for me.
------------------------------------------------------------------------------------
$FONTS = 0x14;
$FromPath = ".\fonts";
$ObjShell = New-Object -ComObject Shell.Application;
$ObjFolder = $ObjShell.Namespace($FONTS);
$CopyOptions = 4 + 16;
$CopyFlag = [String]::Format("{0:x}", $CopyOptions);
foreach($File in $(Get-ChildItem -Path $FromPath)){
If (Test-Path "c:\windows\fonts\$($File.name)")
{ }
Else
{
$CopyFlag = [String]::Format("{0:x}", $CopyOptions);
$ObjFolder.CopyHere($File.fullname, $CopyOptions);
New-ItemProperty -Name $File.fullname -Path "HKLM:\Software\Microsoft\Windows NT\CurrentVersion\Fonts" -PropertyType string -Value $File
}
}
------------------------------------------------------------------------------------
Thanks!!