PS C:\TEMP> $line = "one,3"
PS C:\TEMP> $total = $line.split(",")[1] + $count
--
William Stacey [C# MVP]
PCR concurrency library:
www.codeplex.com/pcr
PSH Scripts Project
www.codeplex.com/psobject
"Frank" <Frank@discussions.microsoft.com> wrote in message
news:F807C9A2-F28F-479C-88AA-C50AF166010D@microsoft.com...
| It is definate that PowerShell is very powerful with hooks to WMI and so
| forth but it appears to be lacking of some string manipulation functions.
I
| am a newbie to PowerShell but I cannot find anything close to the Perl
split.
| I found a regex split but that isn't what I really needed. What I need
is:
|
| my ($f1,$f2) = split (/,/, $record);
| my $total = $f2 + $count;
|
| to split the fields delimeted by a comma, then I would like to deal only
| with field two. Is this possible?
|
| Thanks in advance
|
|