Windows Classroom Session – 28/Sept/2020

Conditionals & looping (contd..)

$servers = @('', '', '', 'asdklfjasdkl')
for($index=0; $index -lt $servers.Length; $index++) {
    echo $servers[$index]
  • while loop:
  • do/while & do until:
    • do while will be executed as long as your condition is true
    • do unitil is inverse of it
    • For Example Refer Here

For Creating Windows Server on AWS Cloud

ERROR Handling

  • try catch & finally

How to work with many powershell cmdlets

  • Start using Cheatsheets. Here is reference to one of many cheats

Next Steps:

  1. Understand Powershell Modules
  2. Understand Thirdparty Powershell Modules
    1. Functions
    2. Cmdlets
  3. Writing a full powershell script which is interactive or silent
Installing IIS8 on your Server. Do you want to Continue? (Y/N)

./InstallWebServer.ps1 -Silent

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

About learningthoughtsadmin