quarta-feira, 27 de novembro de 2013

Criação de Ícone do Datasul na Areá de Trabalho


Criação de ícones do sistema de gestão DATASUL no desktop do usuário toda vez que fazer logon.
Iremos criar um script como icones.vbs a adicionar este arquivo no mapeia.bat conforme mostrei em outro poste em Mapeamento de Unidades.
strWorkDir ="C:\Temp"
strAppPath = "T:\ems\204\scripts\VBS\ems204.vbs"
strIconPath = "T:\ems\204\image\emsdis.ico"
Set objShell = CreateObject("WScript.Shell")
objDesktop = objShell.SpecialFolders("Desktop")
Set objLink = objShell.CreateShortcut(objDesktop & "\PRODUCAO-EMS2.04.lnk")
objLink.Description = "PRODUCAO-EMS2.04"
objLink.IconLocation = strIconPath
objLink.TargetPath = strAppPath
objLink.WindowStyle = 0
objLink.WorkingDirectory = strWorkDir
objLink.Save
strWorkDir ="C:\Temp"
strAppPath = "T:\ems\505\scripts\VBS\ems505.vbs"
strIconPath = "T:\ems\505\image\emsfin.ico"
Set objShell = CreateObject("WScript.Shell")
objDesktop = objShell.SpecialFolders("Desktop")
Set objLink = objShell.CreateShortcut(objDesktop & "\PRODUCAO-EMS5.05.lnk")
objLink.Description = "PRODUCAO-EMS5.05"
objLink.IconLocation = strIconPath
objLink.TargetPath = strAppPath
objLink.WindowStyle = 0
objLink.WorkingDirectory = strWorkDir
objLink.Save
strWorkDir ="C:\Temp"
strAppPath = "T:\hcm\210\scripts\VBS\hcm210.vbs"
strIconPath = "T:\hcm\210\image\emshur.ico"
Set objShell = CreateObject("WScript.Shell")
objDesktop = objShell.SpecialFolders("Desktop")
Set objLink = objShell.CreateShortcut(objDesktop & "\PRODUCAO-HCM2.10.lnk")
objLink.Description = "PRODUCAO-HCM2.10"
objLink.IconLocation = strIconPath
objLink.TargetPath = strAppPath
objLink.WindowStyle = 0
objLink.WorkingDirectory = strWorkDir
objLink.Save
WScript.Quit 

Nenhum comentário:

Postar um comentário