Windows PowerShell is Microsoft's task automation framework, consisting of a command-line shell and associated scripting language built on top of, and integrated with the .NET Framework. PowerShell provides full access to COM and WMI, enabling administrators to perform administrative tasks on both ...

learn more… | top users | synonyms (1)

0
votes
2answers
737 views

Hide Site Pages link from Libraries

I have a sharepoint portal which have hundreds of subsites. The users can create new site and by default when a site is created it has Libraries, lists and discussions link out of the box. I got a ...
2
votes
1answer
2k views

change maxlength of an existing column in a list via powershell?

I have the following code to create a list, however I need to increase via powershell the maxlength of one column $spWeb = Get-SPWeb -Identity http://ost-dev1.ciredev1.local $listTemplate = ...
0
votes
0answers
1k views

enable web analytics customized reports

I'm running SharePoint Server Standard 2010. I don't see a "Customize Report" button in the Analyze tab of the Site Collection Web Analytics report. When I go to PowerShell and run Get-SPFeature ...
1
vote
1answer
1k views

Powershell and SPSecurity.RunWithElevatedPrivileges

I have a couple MOSS dev environments that need to have a script to restore the content databases from production. Part of the script has to set the site collection administrators to the user of the ...
0
votes
1answer
5k views

Powershell command to copy file from Document Library to a fileshare

I have created a WorkFlow to create a document populating it with data from a list. I now need a powershell script that can copy the file in the document library to a file share on our server. I am ...
0
votes
2answers
3k views

Create managed property via powershell?

Is this possible to do via powershell? http://www.glynblogs.com/2011/01/create-a-content-type-search-refinement-panel-in-sharepoint-2010.html#comment-23134 there is nothing to improve in the ...
0
votes
1answer
991 views

Synchronize Documents between SharePoint Farms

I need to synchronize certain documents between 2 Doclibs on different SharePoint Farms. This is a 'one-way-sync' meaning all changes should be replicated from A to B, not from B to A. You can ...
0
votes
1answer
5k views

Change Displayname of list columns via powershell

This code works fine. $spWeb = Get-SPWeb -Identity http://xxx $listTemplate = [Microsoft.SharePoint.SPListTemplateType]::GenericList $spListCollection = $spWeb.Lists ...
2
votes
1answer
980 views

System.ArgumentNullException on feature enabling

I created a vs solution with site columns content type list template list instance. It compiles, it installs correctly, except when I click on activate I got the exception on the ULS logs: ...
0
votes
1answer
3k views

Create a list with powershell

I need to create one list with powershell with the following columns Title Url (255 max length) Description (255 max length) It must be a custom list. There is no need to create site columns or ...
1
vote
2answers
1k views

I cant install a feature

I created a new feature in an existing big solution, I cant just redeploy the solution because it would break many things. What I need is to update the solution and add the new feature, then activate ...
0
votes
1answer
330 views

create a content type managed property via powershell

Regarding this blog post, its very easy to do visually. But for easy deployment on other environments I would like to do this in a powershell script. ...
0
votes
2answers
929 views

Export-SPWeb temporary folder

Anyone knows the location of temporary files that Export-SPWeb uses when exporting sites? One of our servers ran out of drive space when exporting the site and now I can't find the files created by ...
1
vote
2answers
1k views

This powershell runs but why is it so slow

I ran this powershell which automates wsp addition, activate, deploy web parts and it runs fine. However, it takes about 3 minutes to go through the whole process. Is this norm? = = = powershell code ...
1
vote
3answers
2k views

Create Library with PowerShell

I want to create libraries in SharePoint 2010 using PowerShell. So far, so good. I'm using this chunk of code to create the library (actually list, but that doesn't matter) $listTemplate = ...
3
votes
1answer
1k views

I am trying to rename a site using Set-SPSite command

I have created several host-named site collections and now I have to rename a couple. I used the command New-SPSite to create 'http://test1.domain.com' and was able to get everything going fine, but ...
2
votes
1answer
2k views

download profile pictures powershell way

I am using following powershell (that I got from here http://spsatheesh.wordpress.com/2011/06/03/download-all-the-profile-pictures-through-powershell-using-web-service/)so I can download all the ...
0
votes
1answer
4k views

Powershell script to update Navigation.GlobalIncludeSubSites not applying change

I'm using the following PowerShell script to update the Navigation.GlobalIncludeSubSites value from true to false, which is working, except that the changes are not properly applied. By that I mean ...
2
votes
3answers
227 views

How to check if there is any active solution deployment running on the server?

Is there a way to know if there is any active solution deployment running on SharePoint server? I'm wondering how to do this using a PowerShell script?
10
votes
4answers
9k views

How to log off user from SharePoint site, if the user has been inactive for 20 minutes

How to log off the SharePoint site, if the user is has been inactive for for 20 minutes? Do I need to redirect user to logout page? How would I count the idle time?
2
votes
2answers
614 views

Delete List Views

I'm looking to mass delete certain views on a list (about 1000). the naming convention used for the views is [user name] [r#] [view name] view. the # is a value ranging from 1-5 and the view name has ...
2
votes
1answer
3k views

Powershell script to update pages. Dispose page afterwards?

I'm using a PowerShell script to update page titles and PublishingPageLayout's in a particular web that has 391 pages. However, I'm finding that the longer the script runs, the slower each pages is ...
0
votes
3answers
895 views

Is there a PowerShell CmdLet or SharePoint CmdLet that allows reading a Content List?

My eventual goal is to be able to check on new items added to a Content List but I was trying to figure out if there was a CmdLet that could let me access the Content List in a SharePoint Site. I ...
1
vote
2answers
2k views

Powershell: Is disposing of an SPWeb object necissary when its referenced from an SPSIte object?

Edit This is for SharePoint 2007 I have this powershell script: ## Reference to SharePoint DLL [System.Reflection.Assembly]::Load(“Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, ...
0
votes
2answers
323 views

Change SocialTag Url?

I want to change the url of my solution from mycompany.no to mycompany.com. How can I preserve the Social Tags. SocialTag Url property is readonly it appears. :( Does there exist a powershell or ...
1
vote
0answers
208 views

Changing permission level of a document from contribute to read for members

I need a help .... with a powershell script. I have a document and i need to modify the existing permission level for members from 'contribute' to 'read'. Anyone has any idea how to do that? In ...
1
vote
2answers
3k views

deleting managed metadata using powershell script sharepoint 2010

Deleting managed metadata term stores using powershell script. Was trying with the below script but getting error "Cannot index into null array". Please help out thanks in advance.... Add-PSSnapin ...
1
vote
2answers
495 views

A way of setting custom configuration properties that can be changed via power shell

I have a few custom settings for my feature that I am creating. I want a way to populate these values on install with some default values. However if needed an admin should be able to change the ...
2
votes
1answer
243 views

Is there a way to execute commandline-arguments via code from a feature/webpart (Sharepoint 2010)?

I mean, for example, something like a deployment. Is it possible to force something like this from within a webpart using the "standard" sharepoint functionality? Using the central-administration is ...
3
votes
1answer
2k views

How to authenticate when using powershell

I am trying to perform some tasks on user profiles and so, need to connect with different permissions using an account created for that. And, I am doing this with Powershell. Try { $site = ...
1
vote
1answer
313 views

Change owner of all objects

Is it possible to change the owner of all lists, libraries, and pages on SharePoint 2010? Our developers logged in via their personal accounts to the dev server and so SharePoint took their account as ...
2
votes
1answer
1k views

Edit Search Dropdown ScopeDisplayGroup with Powershell Unauthorized

I am trying to edit the Searchbox Scopes dropdown ScopeDisplayGroup using Powershell using the following code (partly backwards engineered from the scope edit layouts page codebehinds): ...
1
vote
1answer
422 views

Unable to get the metadata into list when trying to populate data from csv file using powershell into list

I was trying to import the csv file with 5500 items in it and it is also having metadata items when i try to use powershell script to populate the data from csv to list everything is showing in list ...
1
vote
1answer
3k views

powershell script to add a managed metadata column

$webURL = "http://xxx/sites/wingtipcalculator" $spSite = New-Object Microsoft.SharePoint.SPSite($webURL) $spWeb = $spSite.OpenWeb() $listTemplate = $spWeb.ListTemplates["Custom List"]; ...
0
votes
1answer
942 views

PowerShell script to set default value on a metadata (termstore) column in a SP 2010 document library?

Is there a PowerShell script that will set the default value for a metadata (termstore) taxonomy column in a SharePoint 2010 document library?
4
votes
3answers
8k views

powershell script to add a managed metadata column

I'm looking for a powershell script that allows me add metadata column in SharePoint list. Thanks
3
votes
1answer
549 views

How to create a content source of type “web” with the option “Only crawl within the server of each start address” via powershell

I have a requirement to create a content source of type "web" with the option "Only crawl within the server of each start address" via powershell. I am trying the below command : ...
1
vote
1answer
241 views

Build and package SharePoint2010 solution from PowerShell?

Are there any scripts to build and package a SharePoint2010 solution from directly from PowerShell, instead from Visual Studio 2010?
1
vote
0answers
429 views

Multiple Propset Guid Mapped to a Category

I'm working in a powershell scrip for F4SP 2010 server that reads lines from a .csv file and creates the mappings between managed properties a crawled properties. I don't have much problem, just a ...
0
votes
1answer
3k views

Modifying group owners of sites with ps

I need help here with powershell, as im not that good in, im only starting, but i need already to make a powershell script but will run thru all collaborative spaces and modify 4 groups by setting ...
4
votes
2answers
11k views

How to use GetItems in Powershell to retrieve list items

I'm having issues with this powershell script below. It does work with SP 2007 but won't work with Sp 2010. My goal as you can see is to filter the list returned using the field Date - 1. But getting ...
3
votes
1answer
823 views

How to remove duplicate EventReceiver entries

Lately i had a bug that time-to-time added duplicate event receiver entries in SPEventReceiverDefinitionCollection. So how do i easily enumerate and remove these duplicate entries?
2
votes
2answers
10k views

Permissions error setting up SharePoint 2010 PowerShell account privileges

SharePoint Foundation 2010 SP1 on Windows Server 2008 R2 Std SP1 (Domain Controller) in a simple farm with a single SQL Server 2008 SP1/Windows Server 2008 Std SP2 backend I realise installing SP on ...
3
votes
2answers
200 views

Migrating changes from development site to staging site without doing a content database backup and restore

I wanted to find out the best practice to migrate changes from a development site to staging or production site. I think there should be a better way than backing up the content database on ...
1
vote
2answers
2k views

Get all the machines in a SharePoint farm

I'm writing a really big script which will get a lot of info from my farm. I'd like to make it work dynamically, so I would need to: Get all the database servers in the SharePoint farm Get all the ...
2
votes
2answers
2k views

Restore-SPSite issue with versions

I'm trying to restore a SPSite using Restore-SPSite command. The command returns : Restore-SPSite : Your backup is from a different version of Microsoft SharePoint Foundation and cannot be ...
4
votes
2answers
1k views

Get the check out file based on users Name

My environment is SharePoint 2007. I have write a Power shell script to get the file names and checked out by username and their email id. I am successfully able to get these details. Now I want to ...
3
votes
1answer
935 views

Moving list from one environment to another while preserving the GUID

I have a list template (.stp) file. I would like to restore the list and its contents in any given SharePoint environment. The conditions for restoring are listed below: Restore the list to any ...
6
votes
2answers
695 views

SharePoint 2010 Documentor

Is there already existing a tool , I think "documentor" can be his name for Sharepoint 2010 that can output a form of documentation with a description of all db, web application , sites, sub sites , ...
1
vote
1answer
90 views

Can not turn of notifications (SP 2010)

I'm about to update 300 items in a list that I know lots of users are subscribing to (notification by email on every item update event). I've tried turn this off by using STSADM: stsadm -o ...