I have built a lot of system management tools into AHK, and I'm realizing that using wmic/comspec is going away partially (if not completely).
In trying to get my scripts to work in powershell, I am having a lot of issues. For example, this first code snippet works:
Code: Select all
Run, %comspec% /k wmic /node:"%line%" process call create 'powershell.exe -NoExit -Command Add-WindowsFeature -IncludeAllSubFeature SNMP-WMI-Provider'
Code: Select all
Run, powershell.exe -NoExit -ComputerName %line% -Command Add-WindowsFeature -IncludeAllSubFeature SNMP-WMI-Provider
Code: Select all
Run, %comspec% /k wmic /node:"%A_LoopField%" process call create 'powershell.exe -NoExit -Command Add-WindowsFeature Web-WebServer`,Web-Common-Http`,Web-Default-Doc'
Thanks!!