Learning

Facebook Twitter
A task-based approach to PowerShell cmdlet design Several years ago I had a discussion with a colleague about how Windows PowerShell functions/cmdlets should be designed. As a developer by trade, he liked the idea of having a small number of cmdlets that output objects through several methods. I can definitely see the benefit of this approach -- for a developer. A task-based approach to PowerShell cmdlet design
Santhosh Sivarajan's Microsoft Technology Web Site Scripts and Tools Uninstall Symatec and Install ForeFront Client Serurity - VB Script This script can be use to uninstall Symantec Antivirus client and install Microsoft Forefront Client Security. In this script you will see functions for removing Symantec passwords, uninstalling Symantec Antivirus, uninstalling Symantec Endpoint and installing FCS. Usage: Rename the file extension to .vbs and run as a startup/shutdown GPO. Santhosh Sivarajan's Microsoft Technology Web Site
Powershell Research - System.Security.Cryptography.X509Certificates.X509Store
Creating a Managed Service Account Updated: February 28, 2009 Applies To: Windows Server 2008 R2 This topic explains how to use the Active Directory module for Windows PowerShell to create a managed service account. Creating a Managed Service Account
Create Managed Service Accounts with PowerShell. Do not create managed service accounts with Active Directory Users and Computers. - Active Directory Documentation Team
Getting the Contents of an Active Directory Integrated DNS Zone, Version 2 In June of 2009, I published the first version of Getting the Contents of an Active Directory Integrated DNS Zone. Shortly after that, Chris Dent (chris at highorbit dot co dot uk) published a blog post clarifying the format of the dnsRecord attribute. Most of the time, the difference between the "correct" format and what I had deduced had no effect. Getting the Contents of an Active Directory Integrated DNS Zone, Version 2
Tech Ed 2008 - Demo 2 - Administering Servers in Bulk - Benp's Guide to Stuff Bonjour Bonjour It’s time for Demo 2 – Administering Servers in Bulk. I’ve attached the 4 scripts that I used. Demo 2 – Administering Servers in Bulk Tech Ed 2008 - Demo 2 - Administering Servers in Bulk - Benp's Guide to Stuff
Tech Ed 2008 - Demo 1 - Administering Windows - Benp's Guide to Stuff Hello Again Well I’ve delivered my session “Windows, PowerShell and WMI: Unveiling Microsoft’s Best Kept Secret”, and as promised here are the scripts for the Demo’s I used during my session: Demo 1 – Administering Windows All these demos are simple command lines that I just typed straight in PowerShell, no need for any fancy scripts. Basics Tech Ed 2008 - Demo 1 - Administering Windows - Benp's Guide to Stuff
This article was formerly titled "Automating IT Tasks with Windows PowerShell Overview."** Introduction and Getting Started PowerShell is a vast product, especially when you take into account how it's used in other products such as Lync Server, Exchange, and the Windows Operating System. Windows PowerShell Survival Guide - TechNet Articles - Home - TechNet Wiki Windows PowerShell Survival Guide - TechNet Articles - Home - TechNet Wiki
Note: Notice the news of 2005-04-12! Table of Contents MAML - Overview Microsoft Assistance Markup Language (MAML) is a XML based markup language used by "Longhorn" Help. MAML - Microsoft Assistance Markup Language MAML - Microsoft Assistance Markup Language
Active Directory Powershell Blog
DFS-R Health Report for SYSVOL « blog.powershell.no DFS-R Health Report for SYSVOL « blog.powershell.no Included in the Windows Server 2008 and Windows Server 2008 R2 are the DFS Management-console as well as several command-line tools for administering DFS. A great built-in feature in these tools is the diagnostic reports. This is available in the DFS Management-console: As well as from the DfsrAdmin.exe command-line tool: Using this feature we can generate an HTML-report containing a great overview of the replication health for the SYSVOL replication group:
MSDN

TechNet

Windows PowerShell Survival Guide - TechNet Articles - Home - TechNet Wiki Windows PowerShell Survival Guide - TechNet Articles - Home - TechNet Wiki This article was formerly titled "Automating IT Tasks with Windows PowerShell Overview."** Introduction and Getting Started PowerShell is a vast product, especially when you take into account how it's used in other products such as Lync Server, Exchange, and the Windows Operating System.
Logging All Errors In a previous tip you have seen that cmdlet errors can only be caught by an error handler if the -ErrorAction is set to "Stop". Doing this alters the way the cmdlet works, though. It will then stop at the first error encountered.

Powershell Scripts, Tips and Resources

Use the New Computername Parameter in Windows PowerShell 2.0
Blogs

PowerShell Wiki - PowerShell Wiki
Scripting Series – Interesting things you can do with VBScript and Powershell – Post 1, Self Deletion « .\Matthew Long Posted by Matthew on February 25, 2011 For the first challange i’m going to tackle in this series, we have the problem of self deletion. After quite a bit of experimentation, i found a powershell script cannot delete itself without help from some outside source. Having the script setup a scheduled task on a timer to delete itself is one option, and Scheduled tasks in powershell is certainly well documented on the internet. However, as i already wanted a simple way of students cleaning up their own machines (and telling someone who has never used powershell to run as an admin, set execution policy etc etc isn’t fun) i instead decided to go with a VBScript.
Windows PowerShell Owner's Manual
This morning PowerWF and PowerSE 2.7 were released to the web and they can now be downloaded from http://www.powerwf.com. These releases offer a lot of new value to PowerWF and PowerSE users, as follows: PowerWF 2.7 Highlights New Start Page with New Workflows The start page in PowerWF has been completely redesigned to provide immediate value out of the box for PowerWF customers. The new design highlights the Workflow Library that is included with PowerWF, allowing customers to play workflows in the library without opening a workflow or script document. Poshoholic
When you write a function, you can name a set of parameters and PowerShell will bind command line arguments to them. Any command line argument that is NOT bound do a parameter is available as $args. Let me illustrate: PS>function test ($a) {"Remaing args = $args"}PS>test -A valueRemaing args =PS>PS>test -A value -B value2 -C this is a testRemaing args = -B value2 -C this is a testPS>PS>function test ($a,$b,$c) {"Remaing args = $args"}PS>test -A value -B value2 -C this is a testRemaing args = is a testEric asked me the question, "How can I get ALL the arguments and not just the "remaining arguments". Getting ALL Your Parameters - Windows PowerShell Blog
eBook: Layman’s guide to PowerShell 2.0 remoting
Microsoft Expression Blend - Working with the Canvas Video
Get-credential and Decrypting a SecureString in MSH
Scripting Series – Interesting things you can do with VBScript and Powershell – Post 2, UAC Elevation « .\Matthew Long
Creating Organization chart from Active Directory using Power GUI « Virtualize SharePoint, SharePoint Virtualization, Virtualization Tips
Getting Credentials From The Command Line - Windows PowerShell Blog
Using Get-Credential to Store Passwords “securely” in a file.
HuddledMasses

Debugging using PowerShell ISE102
Debugging using PowerShell ISE 101
Industrial Strength Functions in PowerShell V2 CTP 3
Syntax Highlighting in PowerShell – Precision Computing
More PowerShell Syntax Highlighting – Precision Computing