The following VBS script can be used to install fonts on a computer remotely. It checks to see if the font already exists, and then installs it if it isn't on the computer.
Set wshShell = CreateObject("WScript.Shell")
Set objFSO = createobject("Scripting.Filesystemobject")
Set objShell = CreateObject("Shell.Application")
Set objFolder = objShell.Namespace("\\fileserver\sourcepath")
If objFSO.FileExists(wshShell.SpecialFolders("Fonts") & "\font1.TTF") = False Then
Set objFolderItem = objFolder.ParseName("font1.TTF")
objFolderItem.InvokeVerb("Install")
End If
If objFSO.FileExists(wshShell.SpecialFolders("Fonts") & "\font2.TTF") = False Then
Set objFolderItem = objFolder.ParseName("font2.TTF")
objFolderItem.InvokeVerb("Install")
End If
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.