...
Enable the script to run | ||||||||
---|---|---|---|---|---|---|---|---|
link | ||||||||
Set-ExecutionPolicy Unrestricted
| ||||||||
Hello World | ||||||||
create | create a .ps1 file >>>> write-host "hello world" | |||||||
use ISE | ||||||||
run | > "hello world.ps1" or >& '.\hello world.ps1' | |||||||
Print out | ||||||||
write-host "Welcome to my script" | ||||||||
Loop for | Link | |||||||
Loop while | ||||||||
write-host "Welcome to my script" while ($true){ #test-connection 172.16.128.2 } | ||||||||