Collections:
Other Resources:
Add Comments in Windows PowerShell Scripts
How to add comments in Windows PowerShell scripts?
✍: FYIcenter.com
There are two primary ways to add comments in Windows PowerShell scripts:
1. Using # in the middle of line - If you use the "#" sign in the middle of a line, everything starts from "#" to the end of line is considered as a comment. For example:
Write-Host "Hello World!" # Can you hear me?
2. Using <# ... #> block - If you use the "#" block in a script file, everything between the starting tag and the ending tag is considered as a comment. For example:
<# The following command will
Test connection with the Microsoft Website
Format the output with 2 properties only
#>
Test-Connection www.microsoft.com -count 1 | format-list Address,ResponseTime
⇒ Assign Object to Variable in Windows PowerShell Scripts
⇐ Running Scripts Disabled in Windows PowerShell
2016-11-02, ∼3941🔥, 0💬
Popular Posts:
What is "Human Interface Device Access" in my Windows XP service list? And how is "Human Interface D...
Have a windows 8 computer and need to download the Visual C++ Redistributable for visual studio 2012...
What is "Storage Service" in my Windows XP service list? And how is "Storage Service" service relate...
What is "Remote Access Connection Manager" in my Windows XP service list? And how is "Remote Access ...
What is the "World Wide Web Publishing Service (W3SVC)" system service on Windows Server 2012? Can I...