Getting Started with Windows PowerShell
Published: May 20, 2009
Applies To: Windows PowerShell 2.0, Windows PowerShell 3.0
Windows PowerShell is a new Windows command-line shell designed especially for system administrators. The Windows PowerShell includes an interactive prompt and a scripting environment that can be used independently or in combination.
Unlike most shells, which accept and return text, Windows PowerShell is built on top of the .NET Framework common language runtime (CLR) and the .NET Framework, and accepts and returns .NET Framework objects. This fundamental change in the environment brings entirely new tools and methods to the management and configuration of Windows.
Windows PowerShell introduces the concept of a cmdlet (pronounced "command-let"), a simple, single-function command-line tool built into the shell. You can use each cmdlet separately, but their power is realized when you use these simple tools in combination to perform complex tasks. Windows PowerShell includes more than one hundred basic core cmdlets, and you can write your own cmdlets and share them with other users.
Like many shells, Windows PowerShell gives you access to the file system on the computer. In addition, Windows PowerShell providers enable you to access other data stores, such as the registry and the digital signature certificate stores, as easily as you access the file system.
This Getting Started guide provides an introduction to Windows PowerShell: the language, the cmdlets, the providers, and the use of objects.
- 3/5/2012
- Andrew Shobe
- 5/15/2012
- Hostotosto
I am a SQL DBA and i really want to learn the Windows PowerShell. So would you guys help me in that.
Thanks
Go here:
http://technet.microsoft.com/en-us/library/cc281954.aspx
- 1/18/2011
- SQL_BOSS
- 5/15/2012
- Hostotosto
- 11/15/2011
- FunctionGSolutions
Not sure why cmd.exe is incapable of running PowerShell scripts using the correct interpreter, or why PowerShell can't be made to run the older scripts... Apparently I should have known this somehow.
++++++
Yes you can. Go here:
http://technet.microsoft.com/en-us/library/dd315276.aspx
- 6/29/2011
- Kevin Trumbull
- 10/12/2011
- Sidney H
[TFL] The guide in in the pages following this one - see the tree control in the left pane and use that for navigation
- 6/18/2011
- skitscat1
- 6/20/2011
- Thomas Lee
- 5/28/2011
- jrocks94
What is Windows PowerShell, and what can it do for me? Sorry to be so unfamiliar with technology, however, the powershell is on my computer and I have never used it. Do I really need it?
Thanks for the information. I appreciate it.
Manny
mrobles4@hotmail.com
- 4/11/2011
- Manny67
The answer is really NONE. You don't need any programming experience at all. All of our docs assume that you know nothing about programming, and we try to teach you everything you need to know.
If you find something that's too "programmer-ish" or a doc that uses a concept without explaining it, please let me know. You can file a doc bug on Connect (connect.microsoft.com/powershell) or send mail directly to me: juneb@microsoft.com.
Thanks,
June Blender [MSFT]
Windows PowerShell Documentation
---
Hi June,
Actually this is not really true. When coming from VBScript, if one has no knowledge of C / C++ or C#, the PS syntax is just awfull. VBScript was Visual Basic with a few plus. Visual Basic was the famous Basic+2 language that everyone knows, with a few plus. PowerShell scripting is everything but obvious because of this .NET presence everywhere. However I should agree that the doc is wonderful (except maybe for Error Handling, which is widely spread between MSDN, TechNet and the Scripting Guys Blog...)
- 7/14/2010
- JuneB-MSFT
- 11/17/2010
- Toulousaing - aka DTL
PowerShell scripts are, at least at one level, a program. PowerShell runs your .Ps1 file line by line from top to bottom. But like all classic programming languages, you need to understand two fundamental concepts and how to deal with them in PowerShell. The first is alternation, the second is iterate.
Alternation is where you run different (alternate) code depending on some value or expression - classic If/Then/Else as well as Switch (aka switch) constructs. Iteration is where you want to do something on on some set of values or objects, implemented by a number of constructs in PowerShell, although the two foreach constructs are the ones I find you use most often.
It also helps if you know the .NET framework and WMI as well as a bit of COM. These three provide you with a wealth of configuration and management capabilities and are ideal for scripting.
Thomas
- 8/1/2010
- Thomas Lee
- 11/11/2010
- Lamoskio
Also is it the right way of securing the window application ... help needed ...
- 10/14/2010
- Rai.Gohar
