Sign in
|
Join PowerShell.com!
|
Help
Home
PowerTips
Ask the Experts
Forums
Webcasts
Blogs
eBookV2
Script Library
Twitter Grid
Featured Posts
Dreaming in PowerShell
Don Jones
Code MarkUp Tool
Directory
Richard Siddaway's Blog
»
All Tags
»
Strings
(
RSS
)
Browse by Tags
Share
|
Recent Posts
Working with strings: bits and pieces
Working with strings: I’m a substitute
Working with strings: likes and dislikes
Working with Strings: Simple comparisons
Archives
May 2013 (21)
April 2013 (22)
March 2013 (7)
February 2013 (12)
January 2013 (24)
December 2012 (19)
November 2012 (15)
October 2012 (8)
September 2012 (19)
August 2012 (7)
July 2012 (5)
June 2012 (19)
May 2012 (31)
April 2012 (21)
March 2012 (65)
February 2012 (94)
January 2012 (53)
December 2011 (17)
November 2011 (11)
October 2011 (15)
September 2011 (39)
August 2011 (57)
July 2011 (58)
June 2011 (65)
May 2011 (6)
Tags
Active Directory
Books
COM
Deep Dive
File System
General
Networking
Office 2010
Outlook
Powershell
PowerShell and Active Directory
PowerShell and WMI
PowerShell Basics
PowerShell User Group
PowerShell V2
PowerShell V3
Remoting
Scripting Games
Summit
Technology
Windows 7
Windows 8
Windows Server 2008 R2
Windows Server 2012
Windows Server 8
View more
PowerShell V2
Working with strings: bits and pieces
In the previous post I showed how to generate the parent OUs by splitting and rejoining a string. I used the operators –split and –join These were introduced in PowerShell v2. In PowerShell v1 we had to use the split() method and stitch the thing...
Published
Tue, Jul 07 2011 2:19 PM
by
Richard Siddaway's Blog
Filed under:
PowerShell V2
,
Strings
Working with strings: I’m a substitute
PowerShell string substitution is a very neat trick PS (1) > $string = "World" PS (2) > "Hello $string" Hello World We can substitute the value of the variable into the string. The catch – it only works with double quoted...
Published
Sun, Jul 07 2011 9:38 AM
by
Richard Siddaway's Blog
Filed under:
PowerShell V2
,
Strings
Working with strings: likes and dislikes
Lets start with a string $str = "abcdefghi" We often only have part of a string to work with so we end up using –like $str -like "abc*" $str -like "*abc*" $str -like "*def*" $str -like "*ghi" these...
Published
Sun, Jul 07 2011 4:53 AM
by
Richard Siddaway's Blog
Filed under:
PowerShell V2
,
Strings
Working with Strings: Simple comparisons
Lets start with simple string matching as its a task that frequently comes along "aaa" -eq "aaa" "aaa" -ceq "aaa" both return true. What’s –ceq you ask? PowerShell by design is case insensitive so for...
Published
Sat, Jul 07 2011 4:25 AM
by
Richard Siddaway's Blog
Filed under:
Strings
Copyright 2012 PowerShell.com. All rights reserved.