Sold Out
Book Categories |
Introduction xv
Acknowledgments xx
Finding Your Way Around Windows PowerShell 1
Getting Started with Windows PowerShell 3
Installing Windows PowerShell 3
Installing .NET Framework 2.0 4
Installing Windows PowerShell 7
Starting and Stopping PowerShell 8
Starting PowerShell 8
Exiting PowerShell 10
Startup Options 10
Finding Available Commands 11
Getting Help 14
Basic Housekeeping 17
Case Insensitivity 18
What You Get in PowerShell 19
Interactive Command Shell 19
Cmdlets 20
Scripting Language 21
Summary 23
The Need for Windows PowerShell 25
Limitations of CMD.exe 27
Batch Files 28
Inconsistency of Implementation 28
Inability to Answer Questions 29
Lack of Integration with GUI Tools 29
The GUI Emphasis in Windows 29
Previous Attempted Solutions 29
Windows Script Host 30
WindowsManagement Instrumentation 30
Summary 31
The Windows PowerShell Approach 33
A New Architecture 33
.NET Framework-Based Architecture 34
Object-Based Architecture 35
A New Cross-Tool Approach 38
GUI Shell (MMC Layered over PowerShell) 39
Command Line 39
Command Scripting 41
COM Scripting 43
Namespaces as Drives 45
File System Provider 47
Registry 47
Aliases 48
Variables 49
Active Directory 50
Certificates 51
Extensibility and Backward Compatibility 51
Aliases 51
Use Existing Utilities 53
Use Familiar Commands 55
Long Term Roadmap: Complete Coverage in 3 to 5 Years 55
COM Access 56
WMI Access 56
.NET Class Access 56
Object-Based Approach in PowerShell 56
Object-Based Pipelines 56
A Consistent Verb-Noun Naming Scheme 57
Coping with a Diverse World 58
Upgrade Path to C# 58
Working with Errors 58
Debugging in PowerShell 59
Additional PowerShell Features 59
Extended Wildcards 59
Automatic Variables 60
Summary 62
Using the Interactive Shell 63
Windows PowerShell's Two Command Line Parsing Approaches 63
Expression Mode Examples 65
Command Mode Examples 66
Mixing Expressions and Commands 69
Exploring a Windows System with Windows PowerShell 69
Finding Running Processes 69
Filtering Processes Using where-object 71
Filtering Processes Using Wildcards 72
Finding Out about Services 73
Finding Running Services 74
Finding Other Windows PowerShell Commands 75
Using Abbreviated Commands 76
Command Completion 76
Aliases 77
Working with Object Pipelines 78
Sequences of Commands 78
Filtering Using where-object 79
Sorting 81
Grouping 83
Pros and Cons of Verbosity 85
Interactive 85
Stored Commands 87
Summary 87
Using Snapins, Startup Files, and Preferences 89
Startup 89
Snapins 90
Profiles 97
Profile.ps1 98
Aliases 100
The export-alias Cmdlet 105
The get-alias Cmdlet 107
The import-alias Cmdlet 108
The new-alias Cmdlet 108
The set-alias Cmdlet 109
The Help Alias 111
Command Completion 112
Prompts 113
Preference Variables 115
Summary 116
Parameters 117
Using Parameters 118
Finding Parameters for a Cmdlet 121
Named Parameters 124
Wildcards in Parameter Values 125
Positional Parameters 127
Common Parameters 132
Using Variables as Parameters 133
Summary 135
Filtering and Formatting Output 137
Using the where-object Cmdlet 137
Simple Filtering 138
Using Multiple Tests 140
Using Parameters to where-object 142
The where-object Operators 144
Using the select-object Cmdlet 144
Selecting Properties 145
Expanding Properties 146
Selecting Unique Values 147
First and Last 148
Default Formatting 151
Using the format-table Cmdlet 155
Using the property Parameter 156
Using the autosize Parameter 157
Hiding Table Headers 158
Grouping Output 158
Specifying Labels and Column Widths 159
Using the format-list Cmdlet 161
Using the update-formatdata and update-typedata Cmdlets 162
Summary 163
Using Trusting Operations 165
Look Before You Leap 166
Using the remove-item Cmdlet 166
Using the whatif Parameter 175
Using the stop-process Cmdlet 175
Using the stop-service Cmdlet 178
Using the confirm Parameter 180
Using the verbose Parameter 181
Summary 182
Retrieving and Working with Data 183
Windows PowerShell Providers 183
Using the get-psdrive Cmdlet 184
Using the set-location Cmdlet 188
Using the passthru Parameter 190
Using the get-childitem Cmdlet 191
Using the get-location Cmdlet 194
Using the get-content Cmdlet 196
Using the measure-object Cmdlet 201
The new-item Cmdlet 203
The new-psdrive Cmdlet 204
Summary 205
Scripting with Windows PowerShell 207
Enabling Scripts on Your Machine 207
Using the read-host Cmdlet 212
Using the write-host Cmdlet 214
The Arithmetic Operators 218
Operator Precedence 219
The Assignment Operators 220
The Comparison Operators 222
The Logical Operators 225
The Unary Operators 226
Using the set-variable and Related Cmdlets 227
The set-variable Cmdlet 228
The new-variable Cmdlet 229
The get-variable Cmdlet 230
The clear-variable Cmdlet 231
The remove-variable Cmdlet 232
Summary 234
Additional Windows PowerShell Language Constructs 235
Arrays 235
Creating Typed Arrays 239
Modifying the Structure of Arrays 241
Working from the End of Arrays 245
Concatenating Arrays 248
Associative Arrays 249
Conditional Expressions 250
The if Statement 251
The switch Statement 254
Looping Constructs 256
The for Loop 256
The while Loop 258
The do/while Loop 259
The foreach Statement 260
Summary 262
Processing Text 263
The .NET String Class 263
Working with String Methods 267
Casting Strings to Other Classes 287
URI 287
Datetime 288
XML 289
Regex 289
Summary 291
COM Automation 293
Using the new-object Cmdlet 293
Working with Specific Applications 294
Working with Internet Explorer 294
Working with Windows Script Host 299
Working with Word 301
Working with Excel 302
Accessing Data in an Access Database 303
Working with a Network Share 305
Using Synthetic Types 306
Summary 308
Working with .NET 309
Windows PowerShell and the .NET Framework 309
Creating .NET Objects 311
The new-object Cmdlet 311
Other Techniques to Create New Objects 317
Inspecting Properties and Methods 320
Using the get-member Cmdlet 320
Using .NET Reflection 324
Using the GetMembers() Method 324
Using the GetMember() Method 326
Using the GetMethods() Method 328
Using the GetMethod() Method 329
Using the GetProperties() Method 330
Using the GetProperty() Method 331
Using System.Type Members 333
Summary 334
Putting Windows PowerShell to Work 335
Using Windows PowerShell Tools for Discovery 337
Exploring System State 338
Using the get-location Cmdlet 338
Handling Errors 345
Namespaces 346
PowerShell Aliases 346
PowerShell Functions and Filters 349
PowerShell Variables 350
Exploring the Environment Variables 351
Exploring the Current Application Domain 353
Exploring Services 357
Using the get-service Cmdlet 358
Using the new-service Cmdlet 360
Using the restart-service Cmdlet 361
Using the set-service Cmdlet 362
Using the start-service Cmdlet 362
Using the stop-service Cmdlet 363
Using the suspend-service Cmdlet 364
Summary 365
Security 367
Minimizing the Default Risk 368
The Certificate Namespace 374
Signed Scripts 376
Creating a Certificate 376
The set-authenticodesignature Cmdlet 377
The get-authenticodesignature Cmdlet 379
Summary 379
Working with Errors and Exceptions 381
Errors in PowerShell 381
{dollar}Error 383
Using Error-Related variables 388
Using the {dollar}ErrorView variable 389
Using the {dollar}ErrorActionPreference variable 390
Trap Statement 392
Using Common Parameters 397
Using the ErrorAction Parameter 397
Using the ErrorVariable Parameter 399
The write-error Cmdlet 400
Summary 401
Debugging 403
Handling Syntax Errors 403
The set-PSDebug Cmdlet 408
The write-debug Cmdlet 413
Tracing 418
The trace-command Cmdlet 419
The set-tracesource Cmdlet 422
The get-tracesource Cmdlet 422
Summary 423
Working with the File System 425
Path Names in Windows PowerShell 426
Fully Qualified Path Names 427
Relative Path Names 430
Path Names and Running Commands 431
Simple Tasks with Folders and Files 434
Finding the drives on a system 434
Finding Folders and Files 434
Finding File Characteristics 436
Exploring Files Using the select-object Cmdlet 439
Finding Hidden Files 442
Tab Completion 443
Redirection 445
Creating Custom Drives 447
Cmdlets for File Actions 449
Using the out-file Cmdlet 449
Using Cmdlets to Work with Paths 450
Summary 453
Working with the Registry 455
Introduction to the Registry 455
Exploring the Registry Using Windows PowerShell 458
Selecting a Hive 458
Navigating to a Desired Key 459
Changing the Registry 461
Summary 464
Working with Environment Variables 465
Environment Variables Overview 465
The Environment Command Shell Provider 468
Exploring Environment Variables 470
Modifying Environment Variables 471
Summary 473
Language Reference 475
Working with Logs 477
Event Log Basics 477
The get-eventlog Cmdlet 480
Summary 494
Working with WMI 495
Introducing Windows Management Instrumentation 496
Managed Resources 496
WMI Infrastructure 497
CIM Object Manager 498
The CIM Repository 499
WMI Consumers 499
WMI Tools 499
Using the get-wmiobject Cmdlet 502
Finding WMI Classes and Members 506
Exploring a Windows System 509
Characterizing the CPU 509
Finding Memory 510
Exploring Services 512
Exploring Remote Machines 513
Summary 514
Index 515
Login|Complaints|Blog|Games|Digital Media|Souls|Obituary|Contact Us|FAQ
CAN'T FIND WHAT YOU'RE LOOKING FOR? CLICK HERE!!! X
You must be logged in to add to WishlistX
This item is in your Wish ListX
This item is in your CollectionProfessional Windows PowerShell
X
This Item is in Your InventoryProfessional Windows PowerShell
X
You must be logged in to review the productsX
X
X
Add
Professional Windows PowerShell,
X
X
Add
Professional Windows PowerShell,
|