Sanity check

rated by 0 users
Not Answered This post has 0 verified answers | 1 Reply | 2 Followers

Not Ranked
1 Posts
slkrck posted on 04-19-2012 1:11 PM

I have a SharePoint list with a column call "Documentation". The items in that column are hyperlinks to a folder in library. let's say the link goes to http://portal/sites/New/Foo I want to change the URL to http://portal/sites/NewFoo

Each item in the list has a different URL...points the same library but different folder.  How do I find string in the URL and replace it with something else?




How do I do that in Posh?

All Replies

Top 10 Contributor
640 Posts

Not sure what you meant to paste in there, but it didn't work ;).

But the -replace operator might be what you need.

$newURL = $oldURL -replace "New/Foo","NewFoo"

Is the basic usage.

Page 1 of 1 (2 items) | RSS
Copyright 2012 All rights reserved.