Allow file and print sharing (VBScript)
This code can be found in
Chapter 3 of Windows Server 2003 Networking Recipes
Purchase XP Cookbook or Networking Recipes for only $25 plus shipping! While supplies last.
Find out how to download all of the VBScript code from this site.
' From the book "Windows Server 2003 Networking Recipes"
' This code enables the file and printer sharing exception.
' ------ SCRIPT CONFIGURATION ------
Set Firewall = CreateObject("HNetCfg.FwMgr")
Set Policy = Firewall.LocalPolicy.CurrentProfile
' ------ END CONFIGURATION ---------
Set Services = Policy.Services
Set Service = Services.Item(0)
Service.Enabled = TRUE
WScript.Echo "Setting enabled"
|
This code has been viewed 2992 times.
|
New from the creators of TechTasks.com:
StatSheet.com
|