Hello,
I have a vb scripts that will install a font when I push it through a GPO. It works however, it doesn't check to see if the font already installed. I added additional code I found online to check if the font already exists but it is not working. Can someone take a look? Thanks,
Const FONTS = &H14&
Set objShell = CreateObject("Shell.Application")
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objFolder = objShell.Namespace(FONTS)
If objFSO.FileExists("C:\Windows\Fonts\3of9.TTF") Then
Wscript.Quit
Else
objFolder.CopyHere "\\abc.xxx.com\NETLOGON\3of9.TTF"
End If
I have a vb scripts that will install a font when I push it through a GPO. It works however, it doesn't check to see if the font already installed. I added additional code I found online to check if the font already exists but it is not working. Can someone take a look? Thanks,
Const FONTS = &H14&
Set objShell = CreateObject("Shell.Application")
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objFolder = objShell.Namespace(FONTS)
If objFSO.FileExists("C:\Windows\Fonts\3of9.TTF") Then
Wscript.Quit
Else
objFolder.CopyHere "\\abc.xxx.com\NETLOGON\3of9.TTF"
End If